Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

List Queries in a Combo or List Box

Status
Not open for further replies.

stormking

Programmer
Nov 3, 2001
6
CA
I am trying to put a list of my queries in a combo box so it will list all queries when new queries are added. I can only seem to get the records in a specific query or table, how do I get the list of queries to be listed in the box?
Any SQL or VBA code if needed would be helpful.
Thank you.

Wendy
 
Thank you for the link. I will try this and let you know how this project is going. WSS
 
I have not been able to get the code you pointed me to to work. I keep getting compile errors "expected user-defined type, not project." I had put Access in for Dim Dbs as Database (Database is not an option). Any suggestions?

Thanks
 
Don't know what the problem is there. Try this instead. In the Row Source for your combo box, put

SELECT msysobjects.Name FROM msysobjects WHERE (((msysobjects.Type)=5));


You should then be able to see your list of queries.
 
Thank you Montrose.

The new SQL code worked and brought my queries into my combobox.

Thanks, I may be back while this project continues on. It is getting more involved that I first thought.

Thanks again. wss
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top