PDA

View Full Version : qodbc driver not loaded error in release mode



mandal
10th November 2006, 09:35
Hello.
I am using Visual Studio 2003 and qt 4.2.0. I have 2 projects under my solution. One is a dll that written to access MSSQL Server database with qt libraries. The other is a console application that uses the dll. I have cretaed 2 dlls:I will try to figure out my project settings as detailed as possible.
Release Mode:
name: client.dll client.lib
additional libraraies: qtmain.lib QtCore4.lib QtGui4.lib QtSql4.lib
code generation: Multi-threaded DLL (/MDd)

Debug Mode:
name: clientd.dll clientd.lib
additional libraraies: qtmaind.lib QtCored4.lib QtQtGuid4.lib QtSqld4.lib
code generation: Multi-threaded Debug DLL (/MDd)

project that uses dll:
Debug Mode
Additional Lib: clientd.lib qtmaind.lib QtCored4.lib QtQtGuid4.lib QtSqld4.lib
code generation:Multi-threaded Debug DLL (/MDd)

Release Mode
Additional Lib: client.lib qtmain.lib QtCore4.lib QtQtGui4.lib QtSql4.lib
code generation:Multi-threaded DLL (/MDd)

There is no problem with debug mode but in release mode i have a run time error in my dll usage project that says :
"debug assertion failed..._BLOCK_TYPE_IS_VALID(pHead->nBlockUse)..."
if i change code generation of the project to "Multi-threaded Debug DLL " no pop-up with runtime error but i have an error says:

"QODBC driver not loaded. available drivers: ( nothing is listed in here)"

It is something about my project settings but i couldn 't figured it out.
Thanx a lot for nay help

mandal
14th November 2006, 09:42
i recretaed the project and set all code generation properties to multithreaded debug dll.
Now it runs properly.