View Full Version : How to connect to a SQLServer DB
Helena
10-12-2005, 02:42 PM
Please can you help me to connect to a SQLServer DB using Visual Basic 6.0 .
oracleguy
10-12-2005, 07:30 PM
I'll take a leap here and assume you are refering to connecting to a Microsoft SQL Server from VB6? Or are you using a different database server?
What you need to do is use ADO, it can be referenced into your project which can be done by going to Project > References and then select Microsoft Active Data Objects (i think thats what it is called, I can't remember exactly and I dont have VB6 on my laptop).
Then you can use the ADO objects to use the database. If you already know all that and just need help connecting to the server, just use the regular ADO connection object with the connection string like: "Driver={SQL Server};Server=Aron1;Database=pubs;Uid=sa;Pwd=asdasd;"
vBulletin® v3.8.2, Copyright ©2000-2012, Jelsoft Enterprises Ltd.