By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
440,333 Members | 1,843 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 440,333 IT Pros & Developers. It's quick & easy.

Refreshing links. Good practices/suggestions?

P: n/a
If one distributes a front/backend app is there a good practice for
refreshing the links?

I was thinking that the first time the user enters the app, it could
check for any tables. If the Tables count is 0, have the user select
the backend mdb via a File/Open dialog. Then link all the tables in the
backend and write to a file the name of the backend. Then if I
distribute an update I could simply read that file and refresh the links
based on the filename contained in the file.

When you distribute a frontend, do you do so with no links and instead
use a routine to create the links?

I suppose after the relinking I could also write a text file of all the
table connections as well and use the information it it to refresh the
links in the future when broken by providing an update. Would this
method have any validity?

For some users I'm sure that not all links are coming from MDBs. You
could have a SQL server connect, a text file, an Excel file, a FoxPro
table. Connecting just to the backend may not be enough. How do you
handle the extra non-Access tables as well?
Sep 26 '07 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Salad <oi*@vinegar.comwrote:
>If one distributes a front/backend app is there a good practice for
refreshing the links?

I was thinking that the first time the user enters the app, it could
check for any tables. If the Tables count is 0, have the user select
the backend mdb via a File/Open dialog.
I open a recordset based on a table.
If it pukes then I then look for the below mentioned INI file.
If the INI file exists I attempt to open a recordset based on a table in
that database as mentioned in the INI file.
If the INI file does not exist then I call the File/Open Dialog
If opening the recordset works then I figure the rest of the tables in the
database will work.
>Then link all the tables in the
backend and write to a file the name of the backend. Then if I
distribute an update I could simply read that file and refresh the links
based on the filename contained in the file.
Correct. I use an INI file for this purpose on each apps FE folder on thier PC.
>When you distribute a frontend, do you do so with no links and instead
use a routine to create the links?
No, I distribute my FE's as is with my links in there. The above logic handles the
relinking just fine.
>I suppose after the relinking I could also write a text file of all the
table connections as well and use the information it it to refresh the
links in the future when broken by providing an update. Would this
method have any validity?
No, you just need to path and file name of a valid BE MDB in the file stored in the
local system.
>For some users I'm sure that not all links are coming from MDBs. You
could have a SQL server connect, a text file, an Excel file, a FoxPro
table. Connecting just to the backend may not be enough. How do you
handle the extra non-Access tables as well?
Same but I might have different entries in the INI file if I had multiple files for
different purposes. Although the one time I was upsizing an app I just placed the
server name, instance name and database name in the INI file.

Tony
--
Tony Toews, Microsoft Access MVP
Please respond only in the newsgroups so that others can
read the entire thread of messages.
Microsoft Access Links, Hints, Tips & Accounting Systems at
http://www.granite.ab.ca/accsmstr.htm
Tony's Microsoft Access Blog - http://msmvps.com/blogs/access/
Sep 27 '07 #2

This discussion thread is closed

Replies have been disabled for this discussion.