sam
sam

Reputation: 945

Refresh sharepoint linked table in access db through excel vba

I'm trying to refresh sharepoint linked table in access db using excel vba. I'v created the connection for access db in excel vba

 On Error GoTo ExceptionHandle
 Dim cn As ADODB.Connection, rs As ADODB.Recordset

' connect to the Access database
Set cn = New ADODB.Connection
cn.Open "Provider=Microsoft.ACE.OLEDB.12.0; " & _
"Data Source=C:\sample.accdb;"      
' open a recordset
Set rs = New ADODB.Recordset

but how do i use the method CurrentDb.TableDefs("TableName").RefreshLink . how do i specify the currentdb using with cn.

Upvotes: 0

Views: 526

Answers (1)

Jayant Kumar jain
Jayant Kumar jain

Reputation: 27

I think ADODB does not support CurrentDb method but DAO does.

Upvotes: 0

Related Questions