Show userform and hide excel

Jeorge

New Member
Joined
Nov 27, 2015
Messages
32
Hello there!

I have a userform and created a hide workbook command and a button to show it if I wanted to check the encoded information..
I used this commands on workbook

Private Sub Workbook_Open()

Application.Visible = False
LeaveApplication.Show

End Sub



then I created a button to show excel and inserted the command:

Private Sub ShowWB_Click()

Application.Visible = True
LeaveApplication.Hide

End Sub


Question:

1. Why does my excel file showed up first before userform appear (Which of course loss the privacy of the information entered in a glimpse though), and when userform was closed and open again in a matter of 5 seconds it will then open directly to worksheet without going to the userform.

2. Since I have a button to open my worksheet can I put a command to ask for a password before opening my worksheet to prevent other people to open and see the information encoded in my excel.

Thank you in advance for all the help you can provide.
 

Excel Facts

Fastest way to copy a worksheet?
Hold down the Ctrl key while dragging tab for Sheet1 to the right. Excel will make a copy of the worksheet.
Able to find an answer on my question on number 2, seeking for help on question number 1. Thank you
 
Upvote 0
Why don't you add a worksheet, and just use it as a "splash" screen, giving general information (such as the name of the application, the version number, version date, and so on), and you can hide your data worksheet(s) entirely. The users never need to see anything but your userform and the splash sheet.
 
Upvote 0

Forum statistics

Threads
1,214,830
Messages
6,121,839
Members
449,051
Latest member
excelquestion515

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