mirror of
https://github.com/ultimatepp/ultimatepp.git
synced 2026-05-16 14:16:09 -06:00
22 lines
451 B
C++
22 lines
451 B
C++
#include <SqlCtrl/SqlCtrl.h>
|
|
#include <plugin/sqlite3/Sqlite3.h>
|
|
|
|
using namespace Upp;
|
|
|
|
GUI_APP_MAIN
|
|
{
|
|
FileSel fs;
|
|
fs.Type("Sqlite3 database (*.db)", "*.db");
|
|
fs.AllFilesType();
|
|
LoadFromFile(fs);
|
|
bool b = fs.ExecuteOpen("Open sqlite3 database");
|
|
StoreToFile(fs);
|
|
if(!b) return;
|
|
Sqlite3Session sqlite3;
|
|
if(!sqlite3.Open(~fs)) {
|
|
Exclamation("Can't open database file\n");
|
|
return;
|
|
}
|
|
SQL = sqlite3;
|
|
SQLCommander();
|
|
}
|