relink table to new location

C

CAM

I have a bunch of different frontend that have tables linked from one BE. IT
has just informed me that they are shutting down the server where the BE
lives and replacing it with a new one. This will happen in less than a week.
Not much notice. I know how to go in and using linked table manager, change
the location of the linked tables. My quesition is, is there a faster way
then opening each person's frontend and doing this by hand for all linked
tables using the linked table manager.

Thanks,
Cheryl
 
A

Allen Browne

You can loop through the TableDefs, and set the Connect property of each to
the new location. Don't forget to RefreshLink.

This kind of thing:

Dim db As DAO.Database
Dim tdf As DAO.TableDef

Set db = CurrentDb()

For Each tdf In db.TableDefs
'Skip system and hidden tables, and those with no Connect.
With tdf
If (.Attributes And (dbSystemObject Or dbHiddenObject)) = 0 Then
If Len(.Connect) > 0 Then
.Connect = ";DATABASE=C:\MyNewFile.mdb"
.RefreshLink
End If
End If
End With
Next

Set tdf = Nothing
Set db = Nothing
 
E

Eric Schittlipz

CAM said:
I have a bunch of different frontend that have tables linked from one BE.
IT
has just informed me that they are shutting down the server where the BE
lives and replacing it with a new one. This will happen in less than a
week.
Not much notice. I know how to go in and using linked table manager,
change
the location of the linked tables. My quesition is, is there a faster way
then opening each person's frontend and doing this by hand for all linked
tables using the linked table manager.

Thanks,
Cheryl

Unless there are differences in each person's front end, then re-link the
tables on one copy and save this copy to the server. Then each person can
simply overwrite their old version by dragging a copy off the server.
 
C

CAM

Eric and Allen,
Thanks. There are differences in each person's frontends by now. So, I
will try Allen's solution and see how it goes.

Thank you both very muchl
Cheryl
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top