Skip to Content
Feb 03, 2009 at 10:32 PM

Driver doesnu2019t support version of ODBC behaviour the application requested


Hello fellow developers,

I have just completed a grueling few days tracking down a problem with a VB6 app that prints Crystal Reports using an ODBC connection into a D3 Database and thought I'd share the result as I didn't find too much help on the net relating to my specific circumstance.

The error reported was:

The driver doesnu2019t support the version of ODBC behaviour that the application requested (see SQLSetEnvAttr)

Single stepping through the code showed that the error occurred when actually printing the report:

cryReport.PrintOut NOPROMPT

I spent many hours checking ODBC drivers, database client drivers and even had our tech gurus rebuild my development PC, all to no avail!

Finally, in a fit of desparation, I thought I'd go back to basics. I checked the DSN details over and over to make sure they were correct, as I have several DSNs used for various test and production environments. I used WinSQL to test the DSNs and found one that did not work properly. This prompted me to check the DSNs used to connect to the database in the VB app. In the process of stepping through the code and watching the DSN assignments to the report Tables, I noticed that the password to one of the databases was incorrect. Sending the correct password solved the problem.

I don't know why I received the above error message, I would have expected to see something along the lines of invalid login details, not the cryptic message above.

I hope this post will help some one out in the future as it was certainly quite frustrating and time consuming to track down the solution.

Kind Regards,

Walter Kiess

Senior Analyst/Programmer


Technology that grows with your business