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

What's going on

Status
Not open for further replies.

alib9

Programmer
Nov 12, 2001
5
US
I didn't know what to search for on this one so if anyone could help me then I would be most grateful.

When I run the app, it auto runs a form which I later hide (otherwise it won't go away).

If I then load another form, the program displays it but then carries on executing the rest of the code.

Is there any way (well there must be), to get the user to do something else i.e put an input in, and then carry out a few tasks, before continuing to execute the rest of the code.

Any help would be great.

Thanks in advance
 
You need to use a modal form.
formname.show vbModal
to stop execution until the form is hidden or unloaded.
I usually call a procedure in the form an do a
me.Show vbModal there. When execution resumes I get the values I want to return into local storage, do a me.unload and return the values (unload will clear form level variables if you do a
Set formname = Nothing
which is the only way to completely unload the form). Compare Code (Text)
Generate Sort in VB or VBScript
 
That worked fine thanks JohnYingling
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top