Creates an SQLCipher-encrypted copy of the current unencrypted database. You must have the SQLite3.dll library with SQLCipher extension in order to use this method.
This example opens an unencrypted database and creates a SQLCipher-encrypted copy with the password "11111" in the same folder.
|
|---|
using (var conn = new SQLiteConnection()) {
conn.ConnectionString = @"Data Source=D:\databaseOld.db;Encryption = SQLCipher;";
conn.Open();
conn.SQLCipherExport(@"D:\databaseNew.db", "11111");
} |
|
|---|
Using conn = New SQLiteConnection()
conn.ConnectionString = "Data Source=D:\databaseOld.db;Encryption = SQLCipher;"
conn.Open()
conn.SQLCipherExport("D:\databaseNew.db", "11111")
End Using |