Guest_imported
New member
- Jan 1, 1970
- 0
I have a combo box that allows a user to run a specific query. The main code look slike this:<br><FONT FACE=monospace><b><br>If Me!Combo2.Text = "QueryName" Then<br> stDocName = "Form that runs query"<br>End If<br><br>DoCmd.OpenForm stDocName, acFormDS, , stLinkCriteria<br></b></font><br><br>This opens the form that runs the query. After this is opened, I also have the following line:<br><br><FONT FACE=monospace><b><br>DoCmd.OpenForm "Purchasing Menu", acNormal<br></b></font><br><br>This form has the following subroutine: <br><FONT FACE=monospace><b><br>DoCmd.OutputTo acOutputForm<br></b></font><br><br>What I would like to do is to output the form that is opened <b><i>before</i></b> the Purchasing Menu. Can someone tell me how to supply or get the name of the last loaded form, so I can set the focus to that using DoCmd.SelectObject acForm, stDocName ? <p>John Vogel<br><a href=mailto:johnvogel@homepage.com>johnvogel@homepage.com</a><br><a href= FreeDSL Service</a><br>[To a get FREE DSL Modem WITH FREE DSL Unlimited Internet Connection click the above link ]