Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Forms / November 2006

Tip: Looking for answers? Try searching our database.

ComboBox with Query List?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
bamrak@gmail.com - 30 Nov 2006 12:59 GMT
Good morning!
Is it possible to have a combo box with the list being populated by the
names of all the queries/tables/macros. I know i can make the list
manually, but I was curious as to know if there was a way to have
access manage the list and add/delete as the database grows or shrinks.

Thank you in advance!
Douglas J. Steele - 30 Nov 2006 13:30 GMT
You can get the information from the (normally hidden) MSysObjects system
table.

Queries are:

SELECT [Name]
FROM MSysObjects
WHERE [Type]=5
ORDER BY [Name]

Tables are:

SELECT [Name]
FROM MSysObjects
WHERE [Type] IN (1, 4, 6)
ORDER BY [Name]

(1 are tables in the same database, 6 are linked tables in other databases,
4 are tables linked through ODBC)

Macros would be type -32766, forms would be type -32768, reports would
be -32764 and modules would be -32761.

If you want to unhide the table so that you can work with it, go under Tools
| Options and check System Objects in the Show group on the View tab. (Once
you've created the queries of interest to you, you can uncheck it again and
the queries will continue to work)

Signature

Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no e-mails, please!)

> Good morning!
> Is it possible to have a combo box with the list being populated by the
[quoted text clipped - 3 lines]
>
> Thank you in advance!
bamrak@gmail.com - 30 Nov 2006 13:39 GMT
Doug,
Thank you very much, Great information!
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.