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

Stopping Parent Code while Child Form is Active

Status
Not open for further replies.

Ascentient

IS-IT--Management
Nov 4, 2002
267
I have a main form (frm_main) with a combo box (cbo1) and a command button (cmdSearch). The cmd button launches a form that allows the user to search a query for a customer. When the customer is selected and the form closes it updates the cbo1's value.

What I want to happen is the main form cbo1 box after update event to trigger or be called, so that frm_main updates with that customers informtion.

The issue arises that when I open the search form, the go continues on to the next statement on the main form which tells me that I cannot run the after_update event of cbo1.

I think I have written this clearly but if not please let me know and I will provide more information.
 
You can show a form as modal style, the code will then wait on the show until the loaded form is closed. Note however you cannot display 'child' forms modally, if the child property is true you will need to set it false. This should not cause any problems.

Code:
MyForm.Show vbModal, frm_main


for more info look up the show method for forms.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top