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
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2