Results 1 to 11 of 11
  1. #1
    Lounger
    Join Date
    May 2002
    Posts
    34
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Refreshing Linked tables (97)

    I have a database that Has nothing but linked tables in it. I want to have the tables refresh when the database is opened. How should I do this? I have tried to relink the tables with code, but that isn't going to work the way I want it too!
    Thanks
    DGW

  2. #2
    Gold Lounger
    Join Date
    Jun 2001
    Location
    Crystal Beach, FL, Florida, USA
    Posts
    3,436
    Thanks
    1
    Thanked 34 Times in 34 Posts

    Re: Refreshing Linked tables (97)

    I'm not sure I precisely understand what you are asking. You said you wanted "to have the tables refresh when the database is opened". What do you mean by refresh?
    Mark Liquorman
    See my website for Tips & Downloads and for my Liquorman Utilities.

  3. #3
    Lounger
    Join Date
    May 2002
    Posts
    34
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Refreshing Linked tables (97)

    when you use linked tables in a database, if data is added or updated in the original table does it always update it in the linked table? I was under the impression that this did always happen and it was a good idea to refresh the linked table when it was opened.

  4. #4
    Gold Lounger
    Join Date
    Jun 2001
    Location
    Crystal Beach, FL, Florida, USA
    Posts
    3,436
    Thanks
    1
    Thanked 34 Times in 34 Posts

    Re: Refreshing Linked tables (97)

    Ah, now I understand your question. Unfortunately, you have a misconception of linked tables. A linked table contains no data! It merely points to the real table and data in the other database. The data you see by opening the linked table is in fact the actual data sitting in the real table. Think of a linked table a merely a doorway to the real table. Therefore, there is nothing to "refresh". I hope this helps.
    Mark Liquorman
    See my website for Tips & Downloads and for my Liquorman Utilities.

  5. #5
    Silver Lounger
    Join Date
    Jun 2001
    Location
    Niagara Falls, New York, USA
    Posts
    1,878
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Refreshing Linked tables (97)

    Hi Mark

    Say you have your fe db on drive c: and be db on drive f: on your development system.

    You move it to customes production system fe db on drive c: and be db on drive g:

    When you fire up customes fe how can you automatically link be db to drive g:

    Thanks, John

  6. #6
    Platinum Lounger
    Join Date
    Dec 2001
    Location
    Melbourne, Australia
    Posts
    4,594
    Thanks
    0
    Thanked 27 Times in 27 Posts

    Re: Refreshing Linked tables (97)

    Try the Orders.mdb that is in the samples directory under crogram filesmicrosoft officeoffice and you will find code in the Modules RefreshTableLinks.

  7. #7
    Super Moderator
    Join Date
    Jun 2002
    Location
    Mt Macedon, Victoria, Australia
    Posts
    3,993
    Thanks
    1
    Thanked 45 Times in 44 Posts

    Re: Refreshing Linked tables (97)

    My solution to this problem is to use some DOS. I pretend that I have a g drive by writing a one line batch file:

    C:WINDOWSCOMMANDsubst g: f:johnaccessappselection

    This way my linked tables all are based on the g drive that my customer uses.

    I just have to remember to run the relevant batch file before working on any project. If you add the command line to open the relevant datbase, and use the right workgroup file, to the batch file then it is all accomplished in one operation.
    Regards
    John



  8. #8
    Plutonium Lounger
    Join Date
    Dec 2000
    Location
    Sacramento, California, USA
    Posts
    16,775
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: Refreshing Linked tables (97)

    That will probably get you in trouble in operating systems beyond Win 9x. NT/2000/XP aren't particularly happy with substituted drives, don't run on top of DOS, and if your customer has a network, you may run direclty into conflicts with their network mappings.
    Charlotte

  9. #9
    Platinum Lounger
    Join Date
    Dec 2001
    Location
    Melbourne, Australia
    Posts
    4,594
    Thanks
    0
    Thanked 27 Times in 27 Posts

    Re: Refreshing Linked tables (97)

    Another point to make here is that you should be using UNC (Universal Naming Convention) to specify the path to the database, as all users may not have the g: drive set to the correct path to the database.
    If you specify whereverthenetworkisfirstpathsecondpathetc that means all users can see where the database resides, and will correctly address it.
    HTH
    Pat

  10. #10
    Gold Lounger
    Join Date
    Jun 2001
    Location
    Crystal Beach, FL, Florida, USA
    Posts
    3,436
    Thanks
    1
    Thanked 34 Times in 34 Posts

    Re: Refreshing Linked tables (97)

    First of all, I NEVER use mapped drive letters at client sites. I user the UNC designation to point to the BE database. In Linked Table Manager, this would be done by finding the BE via Network Neighborhood. So instead of GathBE.mdb, it would be servernamecpathBE.mdb, for example.

    One method is to put a copy of the FE on the server, then use Linked Table Manager to link to BE. Then copy FE to each workstation. Since links use the UNC (as described above) , no relinking is required by each workstation.
    Mark Liquorman
    See my website for Tips & Downloads and for my Liquorman Utilities.

  11. #11
    Super Moderator
    Join Date
    Jun 2002
    Location
    Mt Macedon, Victoria, Australia
    Posts
    3,993
    Thanks
    1
    Thanked 45 Times in 44 Posts

    Re: Refreshing Linked tables (97)

    I don't get any of these problems because the substitution is only happening on my computer. I am using substitution to pretend to have the mapped network drive that my client already has. This means I can email a new version of a database and have it work immediately with no changes to the data path.
    I swap over to to UNC paths when the project is more or less complete.
    Regards
    John



Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •