Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Workbook/sheet protection doesn't seem to work
I want to make it so the chart on a chart sheet can't be selected by the
user and I thought protecting the workbook and the worksheet (structure and windows) would do it, but it hasn't worked. ANyone know how to achieve this? Thanks for your help, Mark |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Workbook/sheet protection doesn't seem to work
Perhaps this will solve your problem:
Option Explicit Private Sub Workbook_SheetActivate(ByVal Sh As Object) 'Note: this macro must be stored in the Microsoft Excel Oject: ThisWorkbook Dim strShtName As String strShtName = ActiveSheet.Name If strShtName = "Chart1" Then 'Modify Sheet Name as required Chart1SheetHide MsgBox "You are not allowed to view Chart1" End If End Sub Sub Chart1SheetHide() 'Use this to Hide the Chart1 Sheet: Sheets("Chart1").Visible = False Range("H31:H33").Select End Sub Sub Chart1SheetUnHide() 'Use this to UnHide the Chart1 Sheet: Sheets("Chart1").Visible = True Range("H31:H33").Select End Sub Hope this helps. TTN JMMach, MOUS Master "Mark Stephens" wrote in message ... I want to make it so the chart on a chart sheet can't be selected by the user and I thought protecting the workbook and the worksheet (structure and windows) would do it, but it hasn't worked. ANyone know how to achieve this? Thanks for your help, Mark |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Excel 2007 sheet and workbook protection | Excel Worksheet Functions | |||
Individual sheet protection in shared workbook | Excel Worksheet Functions | |||
sheet and workbook protection | Excel Discussion (Misc queries) | |||
Why does'nt sheet protection allow CTRL+PAGEUP/DOWN to work? | Excel Worksheet Functions | |||
work sheet protection | Excel Discussion (Misc queries) |