Hi All
How do I get my userform to remain open when the following macro runs:
![]()
Please Login or Register to view this content.
Hi All
How do I get my userform to remain open when the following macro runs:
![]()
Please Login or Register to view this content.
Hi,
Is your userform in the same workbook as that macro? If it is, the answer is very simple: you can't because you closed the workbook containing the userform.
Don
Please remember to mark your thread 'Solved' when appropriate.
Hi xlnitwit
Good to hear from you. My UserForm is not in the Workbook that gets opened. I'm not using Unload Me, so am confused. I changed code to the below with a call function and still closes userform...
![]()
Please Login or Register to view this content.
![]()
Please Login or Register to view this content.
Is the userform in the workbook that contains the code you are running - i.e. the InvNoGen routine?
Is there any code run by the workbook you open when it is opened - i.e. does it contain a Workbook_Open event or Auto_Open macro?
Any ideas...Anyone !!!
As far as I can see there's nothing in the code you've posted that would close any userform, unless the userform was in the workbook you were closing.
Is there any other code, or anything else going on?
If posting code please use code tags, see here.
Hi Norie
My thoughts too. The workbook open event, opens up another workbook which hols the following code:
Sub NoGenerator()
Range("A1").Value = Range("A1").Value + 1
Workbooks("No Generator").Close SaveChanges:=True
End Sub
Have you tried putting something simple like a message box in the QueryClose event of the userform?
Then, hopefully, when the useform is getting closed by whatever the message box would popup and you could debug from there to investigate what's going on.
Hi Norie
Pls forgive my ignorance. Have no idea how to do that
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks