Connection to MYSQL

Please support our Visual Basic 4 / 5 / 6 advertiser: Programming Forums - DaniWeb Sister Site
Reply

Join Date: Apr 2008
Posts: 8
Reputation: rustyboy is an unknown quantity at this point 
Solved Threads: 1
rustyboy rustyboy is offline Offline
Newbie Poster

Connection to MYSQL

 
0
  #1
Apr 10th, 2008
I'm new in MYSQL is there anybody who is expert in MSQL as backend and VB6 as front end please i'll be willing to study espcially on the connection. How and what are the procedures?

Thanks a lot in advance...hope to share also my little ideas soon...
Reply With Quote Quick reply to this message  
Join Date: Apr 2008
Posts: 84
Reputation: swapna7999 is an unknown quantity at this point 
Solved Threads: 0
swapna7999's Avatar
swapna7999 swapna7999 is offline Offline
Junior Poster in Training

Re: Connection to MYSQL

 
0
  #2
Apr 17th, 2008
u will require the latest version of Connector / ODBC (formerly MyODBC), (currently 3.51.06).
download and install it.
then use the following code

Dim rs As ADODB.Recordset
Dim adoconn As ADODB.Connection


Private Sub Command1_Click()

Set adoconn = New ADODB.Connection

adoconn.ConnectionString = "DRIVER={MySQL ODBC 3.15 Driver};SERVER=servername;DATABASE=dbname;UID=userid;PWD=password;OPTION=3;"


adoconn.Open

Set rs = New ADODB.Recordset

rs.ActiveConnection = adoconn

rs.LockType = adLockOptimistic

rs.CursorLocation = adUseClient

rs.CursorType = adOpenDynamic

rs.Open "mysql Query "

While Not rs.EOF

Text2.Text = rs!Name 'Name is the field name

g = MsgBox("press ok", 1, "")

rs.MoveNext

Wend

End Sub
Reply With Quote Quick reply to this message  
Join Date: Apr 2008
Posts: 8
Reputation: rustyboy is an unknown quantity at this point 
Solved Threads: 1
rustyboy rustyboy is offline Offline
Newbie Poster

Re: Connection to MYSQL

 
0
  #3
Apr 17th, 2008
Thanks you i'll try to download...and try the code.
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Other Threads in the Visual Basic 4 / 5 / 6 Forum


Views: 723 | Replies: 2
Thread Tools Search this Thread



Tag cloud for Visual Basic 4 / 5 / 6
About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC