Relinking tables (1 Viewer)

Motorhead

Registered User.
Local time
Today, 07:16
Joined
Feb 19, 2002
Messages
11
Hello!

I've got a database wich uses tables of some sub database. How can I relink the tables with code in VBA.
When I change the path of the database he can't find the data of the linked tables and that's not what I wanted.

Hope someone can help me

Greetz,

Martijn
 

chris_visible

Registered User.
Local time
Today, 07:16
Joined
Jan 17, 2002
Messages
24
Did you try using the linked table manager in tools/Database utilities, selecting all tables and the always prompt for new location tick box?

You can re-link the tables in VBA by using the link table command (DoCmd.RunCommand LinkTables) and then renaming all the tables as they were originally, as it duplicates them and puts a 1 after there name.

Hope this helps
 

Motorhead

Registered User.
Local time
Today, 07:16
Joined
Feb 19, 2002
Messages
11
Hello Chris!

Well I've found the linked table manager, and that is exactly what I wanted, only I want to do this in VBA and automaticly.
Maybe you or someone else can help me

Thanx
 

glynch

Registered User.
Local time
Today, 02:16
Joined
Dec 20, 2001
Messages
128
Chris, I have the code to do this but I am currently at a PC without Access and rather than pseudo-coding or guessing I can reply again tomorrow with a real answer.
 

glynch

Registered User.
Local time
Today, 02:16
Joined
Dec 20, 2001
Messages
128
I'm sorry, that last post should have been directed to Motorhead.
 

Users who are viewing this thread

Top Bottom