Removing a Link

M

Mota

Hi;
My FrontEndDB is linked to a BackEndDb having near 80 tables.When i want to
link to another copy of this BackEnd,usually a backup of it,i have to
temporarily remove all links to the current BackEnd and using
TransferDatabase,make near 80 new links to the BackEndCopy.After work is
done,remove all links to the BackEndCopy.mdb,and relink to the main DB
tables back !
Regarding this proccess i have 2 questions:
1-Is there a simpler way to switch between 2 datasource for a FrontEndDB?
2-How to remove a link,other than DoCmd.DeleteObject, not affecting DataBase
size (especially when used together with a relink process),as a much common
way to handle links?

Any feed back would be so much appreciated.Thanx.
 
D

Dirk Goldgar

Mota said:
Hi;
My FrontEndDB is linked to a BackEndDb having near 80 tables.When i
want to link to another copy of this BackEnd,usually a backup of it,i
have to temporarily remove all links to the current BackEnd and using
TransferDatabase,make near 80 new links to the BackEndCopy.After work
is done,remove all links to the BackEndCopy.mdb,and relink to the
main DB tables back !
Regarding this proccess i have 2 questions:
1-Is there a simpler way to switch between 2 datasource for a
FrontEndDB? 2-How to remove a link,other than DoCmd.DeleteObject, not
affecting DataBase size (especially when used together with a relink
process),as a much common way to handle links?

Any feed back would be so much appreciated.Thanx.

Have a look at

http://www.mvps.org/access/tables/tbl0009.htm
 
M

Mota

I have the refreshlinks SubRouthin in my program.What i wanted is switching
between 2 backEnd,or at least ,removing a link.
Thank you.
 
M

Marshall Barton

Mota said:
I have the refreshlinks SubRouthin in my program.What i wanted is switching
between 2 backEnd,or at least ,removing a link.


Take a closer look at that procedure, it does switch the
links from one mdb to another.

Note that it does not use TransferDatabase and it does not
have a need to delete/remove any link to do it. The core
concept is to just reset each TableDef's Connect property to
the path of the other mdb.

If you really need to delete a link, then delete the
TableDef with the link (since about all it has is its
Connect string). This is essentially what your original
DeleteObject is doing.
 

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

Similar Threads


Top