Hide userform's workbook and leave other excel workbooks un-hidden

MBaker25

New Member
Joined
Sep 6, 2014
Messages
7
Hello all,


I created a Userform in Excel 2013 -


I want only the Userform to be visible and it's workbook hidden. The code I'm using does show the Userform, but also hides all open workbooks in excel leaving only the userform visible. What code do I use to only hide the Userform's workbook and leave other open workbooks un-hidden?

The code below is as far as I got -

Private Sub Workbook_Open()

Application.Visible = False
UserForm1.Show

End Sub

I am sure the "Application.Visible = False" is the problem, I tried "Thisworkbook.visible = False" but got an error message. Any suggestions??
 

Excel Facts

Excel motto
Not everything I do at work revolves around Excel. Only the fun parts.
Hi mBaker25,

Try it with

Code:
ThisWorkbook.Windows(1).Visible = False

Cheers,
Alan.
 
Upvote 0

Forum statistics

Threads
1,214,868
Messages
6,122,005
Members
449,059
Latest member
mtsheetz

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top