?
Solved

ADODB Table Names in VB

Posted on 1999-12-10
3
Medium Priority
?
217 Views
Last Modified: 2013-12-25
How do I obtain the table names of an Access database using ADO code in VB?

Thanks in advance.
0
Comment
Question by:bkellerman
  • 2
3 Comments
 
LVL 71

Accepted Solution

by:
Éric Moreau earned 80 total points
ID: 2272183
You query the MSYSObjects table like this:
SELECT * FROM MSYSObjects Where Type = 1

Before querying this table, you must change security settings for this table directly in the database. Go to the Tools menu, Security item and then Authorizations (wording can change as I use a french version of Access and it is MY transalation).
0
 

Author Comment

by:bkellerman
ID: 2272411
How do I enumerate through the table names?

0
 
LVL 71

Expert Comment

by:Éric Moreau
ID: 2272485
The NAME column gives you table names. You can then display them in a listbox or in some other control (maybe you will want to display only table that don't begin by MSYS).
0

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Have you ever wanted to restrict the users input in a textbox to numbers, and while doing that make sure that they can't 'cheat' by pasting in non-numeric text? Of course you can do that with code you write yourself but it's tedious and error-prone …
This article describes some techniques which will make your VBA or Visual Basic Classic code easier to understand and maintain, whether by you, your replacement, or another Experts-Exchange expert.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Suggested Courses

599 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question