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
|
|||
|
|||
How do I close a form that's not being used in Access?
Any advice on how to hide/close forms that aren't being used. Several forms
are used to drill down to detail information. Is there a way to close the forms that are opened to get there? |
#2
|
|||
|
|||
Hi Lisa,
In the event which opens the next form (OnClick or whatever), add a line of code after the openform action to close the current form, like this: DoCmd.OpenForm "NameOfNextFormToView" DoCmd.Close acForm, "NameOfCurrentForm" -- hth, SusanV "Lisa" wrote in message ... Any advice on how to hide/close forms that aren't being used. Several forms are used to drill down to detail information. Is there a way to close the forms that are opened to get there? |
#3
|
|||
|
|||
While Susan is correct, you need to be aware that the Close action/method
*loses* your data without telling you if you have unsaved edits in the form at the time you close it. Details in: Losing data when you close a form at: http://allenbrowne.com/bug-01.html -- Allen Browne - Microsoft MVP. Perth, Western Australia. Tips for Access users - http://allenbrowne.com/tips.html Reply to group, rather than allenbrowne at mvps dot org. "SusanV" wrote in message ... In the event which opens the next form (OnClick or whatever), add a line of code after the openform action to close the current form, like this: DoCmd.OpenForm "NameOfNextFormToView" DoCmd.Close acForm, "NameOfCurrentForm" "Lisa" wrote in message ... Any advice on how to hide/close forms that aren't being used. Several forms are used to drill down to detail information. Is there a way to close the forms that are opened to get there? |
#4
|
|||
|
|||
Really - I never knew that! Thanks for the heads up!
"Allen Browne" wrote in message ... While Susan is correct, you need to be aware that the Close action/method *loses* your data without telling you if you have unsaved edits in the form at the time you close it. Details in: Losing data when you close a form at: http://allenbrowne.com/bug-01.html -- Allen Browne - Microsoft MVP. Perth, Western Australia. Tips for Access users - http://allenbrowne.com/tips.html Reply to group, rather than allenbrowne at mvps dot org. "SusanV" wrote in message ... In the event which opens the next form (OnClick or whatever), add a line of code after the openform action to close the current form, like this: DoCmd.OpenForm "NameOfNextFormToView" DoCmd.Close acForm, "NameOfCurrentForm" "Lisa" wrote in message ... Any advice on how to hide/close forms that aren't being used. Several forms are used to drill down to detail information. Is there a way to close the forms that are opened to get there? |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Losing recordset object with form close and docmd.quit | Bruce | Using Forms | 16 | April 26th, 2005 01:59 AM |
Design help, please | SillySally | Using Forms | 27 | March 6th, 2005 05:11 AM |
Need to clear controls of Filter form | Jan Il | Using Forms | 2 | November 28th, 2004 03:04 PM |
Cant Close form after opening another form??? | Dave Elliott | Using Forms | 3 | October 2nd, 2004 05:30 AM |
dlookup | miaplacidus | Using Forms | 9 | August 5th, 2004 09:16 PM |