Feb 27, 2006 #1 Trudye Programmer Sep 4, 2001 932 US Hey Guys, How do I loop until I can establish an ODBC connection? What should my test/Contional criteria be? if Condition then Go to LoopRound else sConnect = "ODBC;DSN=S_22;DBQ=DSP01;UID=usersmm;PWD=gone; ASY=OFF;DATABASE=" Endif Thanx much, Trudye
Hey Guys, How do I loop until I can establish an ODBC connection? What should my test/Contional criteria be? if Condition then Go to LoopRound else sConnect = "ODBC;DSN=S_22;DBQ=DSP01;UID=usersmm;PWD=gone; ASY=OFF;DATABASE=" Endif Thanx much, Trudye
Feb 27, 2006 1 #2 stix4t2 Programmer Feb 23, 2006 318 US Try puttin the connection string into a connection and testing the connection state. Upvote 0 Downvote
Feb 27, 2006 Thread starter #3 Trudye Programmer Sep 4, 2001 932 US Not sure how to do that. Upvote 0 Downvote
Feb 27, 2006 #4 stix4t2 Programmer Feb 23, 2006 318 US What are you going to do with the connection string when you make a connection? Upvote 0 Downvote
Feb 27, 2006 Thread starter #5 Trudye Programmer Sep 4, 2001 932 US Process normally. I just want to loop until a connection can be made. Upvote 0 Downvote
Feb 27, 2006 #6 stix4t2 Programmer Feb 23, 2006 318 US OK, here is a test to see if you made a connection, does this help? dim conn as connection Dim sConnect As String sConnect = "ODBC;DSN=S_22;DBQ=DSP01;UID=usersmm;PWD=gone; ASY=OFF;DATABASE=" conn.Open sConnect If (conn.State = adStateOpen) Then End If Upvote 0 Downvote
OK, here is a test to see if you made a connection, does this help? dim conn as connection Dim sConnect As String sConnect = "ODBC;DSN=S_22;DBQ=DSP01;UID=usersmm;PWD=gone; ASY=OFF;DATABASE=" conn.Open sConnect If (conn.State = adStateOpen) Then End If