Dim Cnn_Test As New ADODB.Connection Dim Str_Test As StringStr_Test="Provider=SQLOLEDB.1;Persist Security Info=False;Data Source=192.168.0.8; Initial Catalog=Master;"If Cnn_Test.State = 1 Then Cnn_Test.Close Cnn_Test.Open Str_Test, "sa", ""
Data Source=190.190.200.100,1433;Network Library=DBMSSOCN;Initial Catalog=pubs;User ID=sa;Password=asdasd 在www.connectionstring.com里有很多连接字符串
就不用sql身份认证了
Dim Str_Test As StringStr_Test="Provider=SQLOLEDB.1;Persist Security Info=False;Data Source=192.168.0.8; Initial Catalog=Master;"If Cnn_Test.State = 1 Then Cnn_Test.Close
Cnn_Test.Open Str_Test, "sa", ""
在www.connectionstring.com里有很多连接字符串