Code: Select all
const wxString dbFile = wxGetCwd() + "/test.db";
m_textctrl->AppendText(dbFile);
wxSQLite3Database db;
if (wxSQLite3Database::HasEncryptionSupport())
{
db.Open(dbFile, wxString(wxT("password")));
m_textctrl->AppendText("open db with password\n");
}
else
{
db.Open(dbFile);
m_textctrl->AppendText("open db without password\n");
}
unhandled exception An unhandled exception occurred. 试着删除test.db,重新运行,又正常了,关键是我现在想学会后,在程序中打开我已建好的database ,请问,这个问题出在什么地方?