I need help for an application that will give a notification for the user up to 24 hours before their food goes past the use-by date.
I would like the user to be able to enter the food item and the use-by date and then be reminded via notification to use that food item.
Any help on what way to start this and examples would be a great help as i'm pretty new to Java/Android.
Can anyone help me? SQLite Database and notification?
Post a Reply
|Oldest Newest Rating|
· February 10, 2015
Sorry, I can't help you with any code but what I would suggest is that you look hard at what method you're going to use to record the use-by date?
By that I mean that it would likely be unreasonable to expect the user to input that data manually (via key pad) and, off the top of my head, the only speedy way of recording that data would be by scanning the product's bar code.
What I don't know is whether or not a bar code contains the "use by" data, so I would suggest you research that first. Then, if the bar code does contain the "use by" date, look into apps/code that offer the scanning facility.
· February 15, 2015
I can possibly help with the database part. I might now all the syntax at the top of my head. However, there is a class called an SQLiteOpenHelper that you can extend in Java which can help manage queries and create tables and comes with basic SQL functionality. One piece of advice I have is to always use intents. Using intents, you can pass stings on containing some value if it is present and null if it is not. A practical use would be when I basically had 3 tabs, I used the intent to figure out which tab should be loaded switching between activities. Anyway, the main point is that you can pass this information to different activities and use it. If you are unfamiliar with SQL, I highly recommend learning the basics. After learning more about SQL, I feel like I totally did my tables the wrong way.
One last piece of advice is you can always check if your tables have been initialized or not by running a query and seeing if you get any response or not. If you don't then you can initialize your table.
Anyway, Derek Banas has great tutorials on using Database in Android. Admittedly those vidoes are old, but they teach you a lot about how to use databases.
Java / Android Development
Very popular language used to create desktop applications, website applets, and Android apps.
|Bucky Roberts Administrator|