473,657 Members | 2,585 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Checking Linked Access objects via VBA

I have two .mdbs,
MyTestApp.mdb- front end for forms and
MyTestData.mdb-backend for tables.

While the front end is copied to the user's desktop via a batch file,
the front end is linked to the backend currently. I did that
manually. The catch here is that the backend .mdb is used by more
than one application.

I am looking for a way via VBA in my front end app at startup (and the
other ones) to:
1. Interrogate to see if tblA, tblB, & tblC are linked to the
backend .mdb.
2. If the table being checked exists, great. If any of the tables are
missing, I would need to execute a link to the missing table in a VBA
module.

Does someone have a code sample of how this is done? I tried invoking
a table object, but I am experiencing some errors trying to set this
up. (I'm not sure of a generic way to check all of the tables in an
app regardless of their table names or how many tables are there.)

Some other shared objects that need to go on the backend .mdb file are
Reports, Macros, and Queries and a few modules. On this side of
things, do you link to these objects to use them the same way you link
to tables, or is is a bad idea to share objects other than tables?

Thanks for your help...it is appreciated....

Jul 18 '07 #1
1 1711
<rl*********@ya hoo.comwrote
Does someone have a code sample of how this is done?
You can obtain the Developer Solutions example database from
http://support.microsoft.com/kb/248674/en-us. It has not, AFAIK, been
updated since Access 2000 but works with all subsequent versions of Access,
though some of the solutions may differ in detail in Access 2007.

Select "Use multiple databases" as Category of Examples, then choose "Link
tables at startup" (the only example in the category).

When I use similar VBA, I use the code at
http://www.mvps.org/access/api/api0001.htm to allow the user to search and
select files in a comfortable, familiar way (the Windows Common Dialog that
they are used to using in other applications).

Larry Linson
Microsoft Access MVP
Jul 18 '07 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
4819
by: Chris Ritchey | last post by:
Hmmm I might scare people away from this one just by the title, or draw people in with a chalange :) I'm writting this program in c++, however I'm using char* instead of the string class, I am ordered by my instructor and she does have her reasons so I have to use char*. So there is alot of c in the code as well Anyways, I have a linked list of linked lists of a class we defined, I need to make all this into a char*, I know that I...
6
6764
by: Andreas Lauffer | last post by:
I changed from Access97 to AccessXP and I have immense performance problems. Details: - Access XP MDB with Jet 4.0 ( no ADP-Project ) - Linked Tables to SQL-Server 2000 over ODBC I used the SQL Profile to watch the T-SQL-Command which Access ( who creates the commands?) creates and noticed:
5
1804
by: Shane | last post by:
Thanks in advance for the help. I'm new to the STL and havig a bit of trouble figuring out the whole iterator thing. I am using the <list> template and I can insert elements into the list just fine. I just can't get them out. It's like the roach motel! (uh, you can go in, but don't come out... anyway...) Actually, I have been able to get some help from http://www.sgi.com/tech/stl/List.html
20
2676
by: Neil | last post by:
I have an Access 2000 MDB file with a SQL 7 back end. I have a main table with 50,000 records; and I have a selections table with 50,000 records for each machine that uses the database (about 25-50). This allows each user to have their own set of selections. The selections table has three fields: ID (int), Sel (bit), MachName (varchar). ID and MachName comprise the primary key. I have a view that combines the main table and the entries...
2
2683
by: Robert McGregor | last post by:
Hi all, I've got a Front End / Back End database that was working just fine. One day i opened the FE to find that if I tried to open one of the linked tables from the database window, nothing happened (hourglass for about 2 seconds then nothing). I tried relinking the tables and got the same response. (Access even completely bombed out once with a Dr Watson failure).
4
2551
by: Rich | last post by:
I have a access form that is connected to linked sql table via odbc. I have some fields that I dont want to allow nulls when data is entered via the form. I can set the null checking on the SQL server database but the ODBC error tha tis returned is not very polite to the user since it mentions the sql field not the nice label. Is there a way for me to modify this error or put the check in access?
15
7238
by: brettclare | last post by:
I have linked a large SQL Server table to Access, however 'only' 2,195,439 records are shown and are available to query. Can I increase the size (cache??)/number of records showing in Access? Thank you.
2
2099
by: Simon.Whiteside | last post by:
If someone has created a database for me and transferred it over is there any way that I can check I have full access to all areas? I am a beginner with Access and so the development has been done by a temporary employee who has now handed the database over to me. Not that I think he is an untrustworthy character but I would sleep easier at night if I could check he has given me 100% of the database and three months down the line I am...
1
3669
by: BillCo | last post by:
There seems to be a lot of confusion around the groups about linking to an Access mdb with the SQL Server Jet OLE DB provider and I havent been able to find a straight forward solution. Basically, I have an Access MDB (A2K) on one server and a SQL Server DB (2005 std ed.) on another - Both on the same network. I'm trying to create a linked server object in the SQL server to view data in the mdb. I've set it up and it works - but only from...
0
8310
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
1
8503
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8605
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6167
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5632
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4158
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4315
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2731
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1957
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.