Connecting with Visual Basic 6.0

I installed the Sybase Client 12.X and I'm trying to connect with VB6.0.  The current login string that I'm using is as followed:

strLogin = "Provider=Sybase ASE OLE DB Provider;" & _
"Srvr=Server,5000;" & _
"Catalog=DB;" & _
"User Id=user;" & _

But I keep getting "Invalid server name was specified."  I determined that it's coming from the Provider, it has to be because every other command that I remove comes down to the Provider generating it.  I've been having so much difficulty finding a good Sybase driver, without breaking my neck looking all over the country side.  I am wondering, maybe if the drivers that came with WinSQL would work if called apon?  I have tried it, but I got some odd error, that I was not sure about.

Please, I must get this working ASAP.
Who is Participating?
I think the problem you are having is due to the fact that your server is named "Server". Other then that it looks fine to me. (

moorer2kAuthor Commented:
The server of course, is change correctly.  WinSQL tool connects ust fine, and I'm using those same perameters.
>The server of course, is change correctly

I am not sure what you mean here.

> WinSQL tool connects ust fine, and I'm using those same perameters.

Maybe so, but the driver you are using with the VB app may not be ok with it, especially if it is a reserved keyword.
Go to this website to get the correct connection string: you'll be able to find what you need to connect to sybase
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.