Is it possible to close this userform in workbook close,if user forgets to close userform then problem begin.
Is it possible to close this userform in workbook close,if user forgets to close userform then problem begin.
Last edited by zplugger; 08-12-2015 at 10:25 AM.
Put this code into the Workbook BeforeClose Event
Please Login or Register to view this content.
Hi zplugger,
The UserForm should automatically close, when you close the Workbook. If you need to save data from the UserForm before the Workbook Closes, you probably want to use the UserForm_QueryClose routine:
You can take action based on the CloseMode. For CloseMode details see: https://msdn.microsoft.com/en-us/lib.../Gg278635.aspxPlease Login or Register to view this content.
Please note that UserForm2.Hide does not close the UserForm, it only makes the UserForm not visible. For Users of Excel 2007, there are known problems using the .Hide command.
To close the UserForm you need:
LewisPlease Login or Register to view this content.
Thank You for your time LJMetzger
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks