My database is split with front end, back end.
How do I add a new table other than delete the links in the front end, copy the tables from the back end and then split again.
Is there a way to add the new table without all that rigamarole.
I am currently using the code below to re-link after a back end location change.
This works fine but doesn't include any new tables.
How do I add a new table other than delete the links in the front end, copy the tables from the back end and then split again.
Is there a way to add the new table without all that rigamarole.
I am currently using the code below to re-link after a back end location change.
Code:
Public Sub re_Link()
Dim t As TableDef
Dim td As TableDefs
Dim sSource As String
On Error Resume Next
Set td = oDB.TableDefs 'oDB from Daniel Pinault's "Shov"
sSource = TempVars!SRC & "_be.accdb" 'sSource holds the location of the back end files
For Each t In td
If t.Connect <> ";DATABASE=" & sSource Then
t.Connect = ";DATABASE=" & sSource
t.RefreshLink
End If
Next
Set t = Nothing
Set td = Nothing
End Sub
This works fine but doesn't include any new tables.