A.D.TEJPAL
adtp at airtelbroadband.in
Thu Jan 4 23:29:20 CST 2007
Mark, Unload event of main form takes place BEFORE that of the subform. (Interestingly, load event of main form takes place AFTER that of the subform). As a result execution of any code in subform at this stage, that refers to the main form, would attract error. As a remedial action, you can put the following statement at the beginning of relevant code block in the subform: On Error Resume Next Best wishes, A.D.Tejpal --------------- ----- Original Message ----- From: Mark A Matte To: accessd at databaseadvisors.com Sent: Friday, January 05, 2007 01:32 Subject: [AccessD] Closing Subform Hello All, In A97 I have a form with a subform...the subform has a 'Before_Update' event. When I close the main form I get an error that the 'Before_Update'(on subform) event is trying to do stuff and can't find the main form. How should I close the main form? Thanks, Mark A. Matte