Forum Xamarin.Android


The Xamarin Forums have officially moved to the new Microsoft Q&A experience. Microsoft Q&A is the home for technical questions and answers at across all products at Microsoft now including Xamarin!

To create new threads and ask questions head over to Microsoft Q&A for .NET and get involved today.

Save informations in local

Hi, I'm a french student in intership and I have to create an app for scan barcodes, with and without internet connection.

With an internet connection, it's ok, but without, I have to keep the codes scanned in a file.

I've try many things to write in a "file.txt" (others posts : []), but it doesn't work... Sometimes I can write but i can't read because of a sharing violation, sometimes i can't write... etc

Is there an other way to save informations without internet connection? Like a local database, or xml file, or something like this.

I need to write the scanned codes in the file, and when the internet connection come back, i have to synchronize the codes

Thank you by advance and sorry for my english


  • StevenTheEvenStevenTheEven SEMember ✭✭✭

    Fix your problem to read/write. It will not be easier to write/read "xml" then "txt".

  • SKallSKall USMember ✭✭✭✭

    Either use a serializer with read/write or use ORM data provider.

    ORM providers: SQL Cipher (in component store), SQLite-Net, ServiceStack.OrmLite etc.

    Serializers: JSON.Net, RestSharp, ServiceStack.Text etc.

Sign In or Register to comment.