Thursday, February 16, 2012

ADO doesnt connect without network!

Hi!

I wrote an application which connects to a SQL Server / MSDE 2000 DB through ADO components. Now the application doesn't start if I don't have an active network connection; as far as I try to connect, the error I get is:

[DBNETLIB][ConnectionOpen (Connect()).].......

Everything is ok if I simply plug the network cable and let the PC connect to the TCP/IP network.

Hope someone can help me!
Thanks

Umberto...Of course the DB is located on the same PC than the application!

Umberto|||If I write

Data Source=PC_NAME

instead of

Data Source=127.0.0.1

it works fine! Now the question is: WHY??

Umberto|||Is it MSDE or SQL Server Std ?

If MSDE, have you installed Netlib ? It is lhe parameter
DISABLENETWORKPROTOCOL=0
in setup.ini or command line parameters|||Finally I solved the problem by writing:

....;Data Source=(local);....

in the connection string!

Thanks
Umberto

No comments:

Post a Comment