View Single Post
 
Old 04-14-2013, 04:38 AM
niton niton is offline Windows 7 64bit Office 2010 64bit
Competent Performer
 
Join Date: Jul 2012
Posts: 102
niton is on a distinguished road
Default

Quote:
Originally Posted by beginner View Post
Does anyone have VBA code
How to prohibit the use of SHIFT key using VBA when opening excel file
VBA code I want put in Workbook_Open()
You can try forcing users to enable macros.

Hide all sheets on closing. Except for a prompt sheet telling them to enable macros.

Code:
For Each Sheet In Sheets 
    If Not Sheet.Name = "Prompt" Then 
        Sheet.Visible = xlSheetVeryHidden 
    End If 
Next
Unhide on opening, if macros are enabled.

Code:
For Each Sheet In Sheets 
    If Not Sheet.Name = "Prompt" Then 
        Sheet.Visible = xlSheetVisible 
    End If 
Next 

Sheets("Prompt").Visible = xlSheetVeryHidden
http://www.vbaexpress.com/kb/getarticle.php?kb_id=578



*******************
Consider rating the thread by going to the "Rate Thread" dropdown.
Reply With Quote