hiding sheet --authorised use only

arjaffari

Board Regular
Joined
Jul 5, 2008
Messages
61
is there any way so the sheets may be hidden for any unauthorized use and may only be viewable by authorized persons
 

Excel Facts

Does the VLOOKUP table have to be sorted?
No! when you are using an exact match, the VLOOKUP table can be in any order. Best-selling items at the top is actually the best.
is there any way so the sheets may be hidden for any unauthorized use and may only be viewable by authorized persons

I think this is the same question you asked one more time.

Follow these steps:

Excel menubar --> click on Format --> Sheet --> Hide. Next, protect your worksheet with a password. This will help you to accomplish your question requirement.

In order to protect your worksheet with a password:

Excel Menubar --> Click on Tools --> Protection --> Protect Sheet --> Apply Password and you are done.
 
Upvote 0
the process has only one problem when the application is distributed and we dont want everybody to see or access the hidden sheets except from the autorised person.

In this case is there a way out???
 
Upvote 0
You can unhide sheets using a macro, which could be executed only by authorised person.
 
Upvote 0
something like this in the ThisWorkbook module might work.

Code:
Dim LastSheet as Worksheet

Private Sub Workbook_SheetActivate(ByVal Sh As Object)
    Dim showSheet As Worksheet
    If Sh.Name = "SecretSheet" Then
        Application.EnableEvents = False
        lastSheet.Activate
        Set showSheet = IIf(Application.InputBox("What is the password", Type:=2) = "password", Sh, lastSheet)
        showSheet.Activate
        Application.EnableEvents = True
    End If
End Sub

Private Sub Workbook_SheetDeactivate(ByVal Sh As Object)
    Set lastSheet = Sh
End Sub
 
Upvote 0

Forum statistics

Threads
1,214,827
Messages
6,121,816
Members
449,049
Latest member
cybersurfer5000

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