first of all, i know that this is an linker-error, but i can't fix it on my own ... maybe im just blind.
I'm Using Windows Vista, with CodeBlocks 8.02, wxwidgets 2.8.9, wxsqlite3 1.9.4
As is startet trying to include wxsqlite, my problems startet. I compiled it with the same option as i compiled wxwidgets. I tried to copy the first few lines from the sample which is included in wxsqlite into my code, which resulted in the following lines.
Code: Select all
obj\Debug\En_MaxApp.o||In function `_Z6initDBv':|
E:\en max\En Max\En_MaxApp.cpp|34|undefined reference to `wxSQLite3Database::wxSQLite3Database()'|
E:\en max\En Max\En_MaxApp.cpp|35|undefined reference to `wxSQLite3Database::Open(wxString const&, wxString const&)'|
E:\en max\En Max\En_MaxApp.cpp|36|undefined reference to `wxSQLite3Database::ExecuteUpdate(wxString const&)'|
||=== Build finished: 3 errors, 0 warnings ===|
Code: Select all
#ifdef WX_PRECOMP
#include "wx_pch.h"
#endif
#ifdef __BORLANDC__
#pragma hdrstop
#endif //__BORLANDC__
#include "En_MaxApp.h"
#include "En_MaxMain.h"
#include "EnMaxClass.h"
#include "wx/wxsqlite3.h"
#include "wx/wxsqlite3opt.h"
IMPLEMENT_APP(En_MaxApp);
wxSQLite3Database* initDB(void)
{
wxString testDBName = wxGetCwd() + _T("/test2.db");
if (wxFileExists(testDBName))
{
wxRemoveFile(testDBName);
}
wxSQLite3Database* db = new wxSQLite3Database();
db->Open(testDBName);
db->ExecuteUpdate(_T("CREATE TABLE test (col1 INTEGER)"));
return db;
}
bool En_MaxApp::OnInit()
{
GUIFrame* frame = new GUIFrame(0L);
frame->SetIcon(wxICON(aaaa)); // To Set App Icon
frame->Show();
return true;
}
Please give me a hint what i did wrong or what i missed.
Thanks
Nala