Create a list box of available forms

Wavona

Registered User.
Local time
Today, 14:38
Joined
Sep 18, 2013
Messages
14
Hello there Access Experts,
Can you help me solve this problem?

I want to create a list box that contains a list of all the available forms in my database. I don't know how to write code, so I would appreciate a kind soul explaining how I can go about doing this in very simple English please!

Many thanks for your help.

Kind regards,
Anna
 
The question hints at a design problem, but as the row source of the listbox:

SELECT msysobjects.Name
FROM msysobjects
WHERE msysobjects.Type=-32768
 
Many thanks Paul, that worked very well.

Regards,
Anna
 
I am new to access and still learning. I am looking to do the same thing. I opened a form in design mode, added a list box, opened property box and added this to the row source
SELECT msysobjects.Name FROM msysobjects WHERE msysobjects.Type=-32768
Ran form, but it does not work.
Please help me with this. Also I would like to know if there is a way to do this with only selects forms (not all of them).
Thanks for your help with this.
 
Not sure what "does not work" means exactly. It worked in the 2007 db I tested on, and apparently for Anna. You could probably do select forms if there was something in the name that identified the ones you wanted (or didn't want). And it still hints at a design problem.
 
Sorry, when I ran the form the list box it kept coming up blank. I noticed that my row source type was blank. My mistake, sorry. It works now. Could you give me an idea on how to filter out forms that we only want to show? Maybe if we put and * at the end of the form name.
Is there a way to filter this? Again thanks.
 
I see you posted the question again, so I won't waste much time on it. You definately don't want "*" in an object name. You could do something like

WHERE msysobjects.Type=-32768 AND msysobjects.Name Like "Something*"
 
Thank you for taking the time to answer. this will work out great. I am sorry if you think you are wasting your time. Thanks agian.
 

Users who are viewing this thread

Back
Top Bottom