This is my code for the Workbook:
I've got a userform with a button. This button shows another userform with another button:
-Userform2
Now in this second userform, got another button that clicking on it, creates a new workbook, saves it and closes it:
-Userform1
As you can see in the Open Workbook sub, I've got the Application.Visible = False, so when I run the file, it wont show me the current worksheets nor the workbook, just the userforms created.
Everything works, but at the end of the sub for the new workbook, the current workbook makes itself visible. Let's say the workbook's name for the application created it's called "BOOK.xlsm" (where I have my VBA code), so when I run the app, the workbook "BOOK.xlsm" doesn't show. So far so good. When I run the macro (click button) to create, save as, and close a new workbook and finishes (that works correctly), the workbook "BOOK.xlsm" shows up behind the forms of the application aaaaand that's what I dont want to happen. I want to be able to finish the macro, and let the forms right there, with the "BOOK.xlsm" not showing up, just the userforms as it should be.
What can I do?
Bookmarks