Thanks for your reply..Sure that I have read cookbook.
But still I am at initial phase only.
My system is 64bit windows 7 OS.I have placed all dlls in system32 and 64 folders unfortunately not able to load the spatialite dll into qt which I can read the shapefile data in my program.
if (!sdb.open()) {
qDebug() <<"Errorrrrrrrrrrrrr11111111";
}
QSqlQuery tSqlQuery(sdb);
QVariant v = sdb.driver()->handle();
if (!v.isValid() || qstrcmp(v.typeName(), "sqlite3*") != 0) {
qDebug()<<"Cannot get a sqlite3 handle to the driver.";
}
sqlite3* handler = *static_cast<sqlite3**>(v.data());
if (!handler) {
qDebug()<<"Cannot get a sqlite3 handler.";
}
int ret = sqlite3_enable_load_extension(handler,1);
if (ret != SQLITE_OK)
{
qDebug()<<"cannot load extension : \n";
}
if(sdb.isOpen())
{
if(!tSqlQuery.exec("SELECT load_extension('libspatialite-4.dll')"))
{
qDebug() << tSqlQuery.lastError();
}
}
displaying error: QSqlError("1", "Unable to execute statement", "no such function: load_extension").
Please suggest me any soln to fix this.