View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.misc
Mike H Mike H is offline
external usenet poster
 
Posts: 11,501
Default Block Printing of sheet

Hi,

Alt + F11 to open VB editor. Double Click 'This Workbook' and paste this in
on the right

Private Sub Workbook_BeforePrint(Cancel As Boolean)
If ActiveSheet.Name = ("Sheet1") Then
MsgBox "You cannot print this sheet"
Cancel = True
End If
End Sub

Mike

"Shu of AZ" wrote:

I have two worksheets, sheet1 and sheet2. Is there code to block sheet1 from
printing without having to place the print area in some distant cell and
protect the sheet.