Reputation: 2445
I have searched around a lot but have not found much of anything in regards to local storage for Windows 8 metro apps. Does anyone know of any easy way to create a local storage DB with basic save()
and load()
functions?
All I need is to bind some XAML
to some data (titles, descriptions etc). I have made windows phone 7 apps before using Isolatedstoragesystem but obviously it is different for windows 8... documentation didn't help much either >.< Any tips appreciated.
Upvotes: 2
Views: 6258
Reputation: 2388
Lex.Db seems to be pretty nice on a cursory inspection. I just tested it in a win rt project. It is available on nuget. https://github.com/demigor/lex.db
Upvotes: 1
Reputation: 23754
You have a spectrum of options available to you, and there are code samples you should check out - specifically the Application Data Sample at the Windows Dev Center
You could use app file storage, local data (dictionary stored on device), roaming data (dictionary stored in the cloud) - all of which are accessible via Windows.Storage.ApplicationData.Current. For example,
Windows.Storage.ApplicationData.Current.LocalSettings.Values["FirstName"] = "Joe"
Beyond that you could pull in SQLite for relational type storage managed in-process.
Upvotes: 8