You are here: > ESRI Forums > arcgis desktop discussion forums > Thread Replies

ArcGIS Desktop Discussion Forums

ArcGIS Desktop - ArcObjects Visual Basic for Application (VBA) forum

SQL Server Connection   Travis Gorrie Apr 29, 2009
Re: SQL Server Connection   Travis Gorrie Apr 30, 2009
Report Inappropriate Content • Top • Print • This Forum is closed for replies.    
Subject SQL Server Connection 
Author Travis Gorrie 
Date Apr 29, 2009 
Message Having trouble connecting to SQL Sever 2008 from ArcMap 9.2 programattically (it works from ArcCatalog). Obtained the connection string from http://www.connectionstrings.com to ensure correct syntax. It always states that it could not connect via my login instead of using the user\password that I pass in with the string.

Any thoughts? Is there a bug that gets resolved with 9.3?

Thanks. 
 
Dim adoConnection As ADODB.Connection
Set adoConnection = New ADODB.Connection
    
adoConnection.Open "Driver={SQL Server};Server=COSEDWASPROD;Database=Safety;UserID=login;Password=pswrd;Trusted_Connection=False;"

 
   
Report Inappropriate Content • Top • Print • This Forum is closed for replies.    
Subject Re: SQL Server Connection 
Author Travis Gorrie 
Date Apr 30, 2009 
Message Resolved. Solution below. 
 
adoConnection.Open "Driver={SQL Server};Server=COSEDWASPROD;Database=Safety;User ID=Read;Password=pswrd;"