I’m pretty new to android can some one give me a better idea which one is a better way to save 2 edit texts on activity 1 and 24 edit texts on activity 2.
i need to save it with date / time stamp
and
be able to open by linking with onClick of a button.
what is the best option: shared preferences, sql db or file?
Please help me out here.
Really it depends on what your application is going to do with that information and how you intend to use it.
Based on what you’ve briefly described, I’d recommend using an SQLite DB (with or without a Content Provider) to store the information just based on the fact that you’re looking for a date/time stamp. Plus, it gives you a lot of flexibility going forward and it’s not like there is a ton of overhead in that approach.
Shared Preferences are great too, but mainly are for key/value pairs and aren’t nearly as flexible.
Last but not least, this question has some good info on using SQLite DB on Android and the differences in using a content provider vs. not.