christywarner
Programmer
hi,
I have an Access front-end w/ an SQL Server
back-end, and want to know how I can check to
see if a file exists on the SQL server?
My code gives me an error when the file
doesn't exist:
Dim rs As ADODB.Recordset
Dim cn As ADODB.Connection
Dim db As Database
Dim cstring As String
Set rs = New ADODB.Recordset
Set cn = New ADODB.Connection
cstring = "provider=MSDASQL.1;User ID=guest;password=; Initial Catalog=Master; Data Source=cwsqlserver"
cn.ConnectionString = cstring
cn.Open
rs.ActiveConnection = cn
rs.Open
how can I check to see if the file exists
before calling the "rs.open"?
thanks!
Christy.
I have an Access front-end w/ an SQL Server
back-end, and want to know how I can check to
see if a file exists on the SQL server?
My code gives me an error when the file
doesn't exist:
Dim rs As ADODB.Recordset
Dim cn As ADODB.Connection
Dim db As Database
Dim cstring As String
Set rs = New ADODB.Recordset
Set cn = New ADODB.Connection
cstring = "provider=MSDASQL.1;User ID=guest;password=; Initial Catalog=Master; Data Source=cwsqlserver"
cn.ConnectionString = cstring
cn.Open
rs.ActiveConnection = cn
rs.Open
how can I check to see if the file exists
before calling the "rs.open"?
thanks!
Christy.