I programmed a c# application that can work on any other computer so i used from sqlite database.I want to backup and restore data in this app.for backup it's ok.I use from below code:
private void button1_Click(object sender, EventArgs e)
{
using (var source = new SQLiteConnection("Data
Source=bazarganidb.db;version=3"))
using (var destination = new SQLiteConnection("Data Source=" + textBox1.Text + "/" + DateTime.Now.ToString("yyyyMMdd") + "backup.db"))
{
source.Open();
destination.Open();
source.BackupDatabase(destination, "main", "main", -1, null, 0);
}
}
But i dont know about restore.how can i restore the database wichi backuped? I searche alot but no result.