Run Query from a continious form that references table

jgabel

Registered User.
Local time
Yesterday, 20:02
Joined
Mar 29, 2012
Messages
42
I'm really green when it comes to front end side of MS Access and forms, and I can really use your help.

I have a table called Tbl_Query_List that houses the query names that I want to be displayed on a continuos form. I want the user to select the query by highlighting it in the continious form and then having a command button at the bottom of the form.

I have everything setup including the command button. Assuming that on the EVENTS tab I set the OnClick to [Event Procedure] but when I click on the ellipsis what do I type to make it run the highlighted query?
 
How about Making the form a Single form with only two controls one combo box and one command button, the combo box will list all Queries, then use the command button to run the query based on the combo box selection?
 
Thank you kindly for your quick response!

This sounds like the easier approach, but I like my continious form in that nicely displays the queries along with a query description, is it possible to use the continious form by highlighting the query within the table and having a command button to run the highlighted query?

This would be my preferred method :)
 
Can you tell us in 1-2 lines exactly WHAT you are trying to do?
What would the output look like --sample please.
 
From the main form I want to display a continuous form showing the selected queries in my table called Tbl_Query_List. Below the form, I want to a Command button for the user to run and display the query results once they click the highlighted query and then they select the Run Query command button. Thank you kindly!
 
Continous Form:

query_test -this is query description test 1
query_test2 - this is query description test 2

Command Button below continious Form
"Run Query"

User needs to highlight query in continous form then they hit the Run Query command button at bottom of form

Thanks again!
 
Why a continuous form?
If you have a single record form with a combo or listbox with all of your queries, couldn't the user select the query, hit a button or dbl click and see the sql for the query and then the output from running the query?

These would all be select queries also , right?
You wouldn't want to delete/insert/append records based on user whims.

I attached a Form that I have that Identifies all Forms and will show those forms when the combo entry is selected and the button is pushed.
 

Attachments

  • FormToPrintForms.jpg
    FormToPrintForms.jpg
    94.3 KB · Views: 109
Last edited:
I like the look of the continous form in that I do not have to click on a small combo box and I would like to incorporate the query description, but if this is the best way I can give it a shot.

So if I do the Combo Box I can place a Command button next to it, can you help me with the run command?

Assuming that on the EVENTS tab I set the OnClick to [Event Procedure] and then do I click on the ellipsis and indicate the command? My table name that combo box would be referencing is called Tbl_Query_List.

I APPRECIATE your help!!
 
Where are you getting the description of the query?
How many queries are involved? These are Select (Read Only) queries.
 
My query description is a text field in my "Tbl_Query_List".

I have 2 fields within this table - query name and desc.

I do not have any action queries, just a select query with parameters that the user will input.
 
I'm trying a combo box in my form that retrieves the queries in the table. Can you help me the command button to run the query that's within the combo box? I can add a command button, I just don't know how the properties of the command button. Sorry to be such a novice at this.
 

Users who are viewing this thread

Back
Top Bottom