If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
|
#1
|
|||
|
|||
Open form behavior
I have a form frmLookup that displays all of the programs. If the user click
the button next to that program it will open a new form frmEvent with all of the program information. frmevent is opened using the following code stDocName = "frmEvent" stLinkCriteria = "[programid] = " & Me.ProgramID stOpenArg = "" DoCmd.OpenForm stDocName, , , stLinkCriteria, , , stOpenArg frmLookup does not close. frmEvent has alot of subfrms on it as well. There is code on the form_unload event of some of these subforms. I have found out that some users are not closing frmEvent before they load another program. With frmEvent still open and displaying the information about programA they are bringing up the lookup screen and choosing another program say ProgramB. Since frmEvent is already open, when the docmd.openform is called to display the information of programB, does Access realize the form is already open and just requery the data for the new program or does it actually close the form and reopen it. I need to know this to determine if the form_unload events are being called in this scenario. |
#2
|
|||
|
|||
Open form behavior
On May 2, 11:09 pm, Rickety107
wrote: I have a form frmLookup that displays all of the programs. If the user click the button next to that program it will open a new form frmEvent with all of the program information. frmevent is opened using the following code stDocName = "frmEvent" stLinkCriteria = "[programid] = " & Me.ProgramID stOpenArg = "" DoCmd.OpenForm stDocName, , , stLinkCriteria, , , stOpenArg frmLookup does not close. frmEvent has alot of subfrms on it as well. There is code on the form_unload event of some of these subforms. I have found out that some users are not closing frmEvent before they load another program. With frmEvent still open and displaying the information about programA they are bringing up the lookup screen and choosing another program say ProgramB. Since frmEvent is already open, when the docmd.openform is called to display the information of programB, does Access realize the form is already open and just requery the data for the new program or does it actually close the form and reopen it. I need to know this to determine if the form_unload events are being called in this scenario. It will not close the form, it will just remove the filter and then filters it again for the new value. It however, "saves" the record,i you want the events in the unload to happen, by refiltering the form, it'd be more practical to put those in the afterupdate event of the form. |
Thread Tools | |
Display Modes | |
|
|