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 derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Opening a form from a command button

Status
Not open for further replies.

eavan

Technical User
Aug 6, 2003
51
GB
Hey guys,

i am clicking a command button which opens a form up.
Problem is this form was setup based on a query and therefore it is looking for query details. The user of the system will select some details on a listbox and click this button. I have this statement in the onClick property,[Case number]=[Forms]![Assigned test list]![List0], but the query is looking for the same details.I want to stop this form query prompt coming up.How do i do this would you know. Basically, the selection in the listbox ought to be the query condition criteria.Thanks
 
Place [Forms]![Assigned test list]![List0] on the criteria line of your query. By the way, for this to work, the form must stay open.
 
As Fneily said,

Set the On Open property of the opening form

Forms![assigned test list].Visible = False


Then for the opening form, the On Close property

DoCmd.Close acForm, "assigned test list
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top