Q

Code to connect SQL Server 7.0 to Visual Basic 6.0

Get the code to connect SQL Server version 7.0 to Visual Basic 6.0.

I would like to know how to connect SQL Server 7.0 to Visual Basic 6.0. Can you please give me the codes?
This code can be used for the connection:

Public adoconn as ADODB.Connection

Sub main()
Set adoconn = New ADODB.Connection
adoconn.ConnectionString = "Driver={SQL
Server};Server=myServerAddress;Database=myDataBase;Uid=myUsername;Pwd=m
yPassword;"
adoconn.Open
End Sub

This was first published in December 2007

Dig Deeper

PRO+

Content

Find more PRO+ content and other member only offers, here.

Have a question for an expert?

Please add a title for your question

Get answers from a TechTarget expert on whatever's puzzling you.

You will be able to add details on the next page.

0 comments

Oldest 

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to:

-ADS BY GOOGLE

SearchBusinessAnalytics

SearchDataCenter

SearchDataManagement

SearchAWS

SearchOracle

SearchContentManagement

SearchWindowsServer

Close