Hi. i am working with small windows form application C# that save changes on an online database. But i want if user in offline mode/no internet to save data in a temp file, then automatically synchronous with the online database and save changes.
1 Reply
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.

Sushil GuptaPosted Dec 17, 2014, 12:21 PM
if (!File.Exists(@"C:\File.txt"))
System.IO.File.WriteAllText(@"C:\File.txt");
else
File.AppendAllText(@"C:\File.txt");
Later once connection is back you can copy that file back to server.