Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if (!System.IO.File.Exists("C:\Users\abc\Desktop\1\synccc.sqlite"))
- {
- Console.WriteLine("Just entered to create Sync DB");
- SQLiteConnection.CreateFile("C:\Users\abc\Desktop\1\synccc.sqlite");
- string sql = "create table highscores (name varchar(20), score int)";
- SQLiteCommand command = new SQLiteCommand(sql, sqlite2);
- command.ExecuteNonQuery();
- }
- sqlite2 = new SQLiteConnection("Data Source=C:\Users\abc\Desktop\1\synccc.sqlite");
- if (!System.IO.File.Exists("C:\Users\abc\Desktop\1\synccc.sqlite"))
- {
- Console.WriteLine("Just entered to create Sync DB");
- SQLiteConnection.CreateFile("C:\Users\abc\Desktop\1\synccc.sqlite");
- using(var sqlite2 = new SQLiteConnection("Data Source=C:\Users\abc\Desktop\1\synccc.sqlite"))
- {
- sqlite2.Open();
- string sql = "create table highscores (name varchar(20), score int)";
- SQLiteCommand command = new SQLiteCommand(sql, sqlite2);
- command.ExecuteNonQuery();
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement