How do I stop a worksheet from being printed
Posted by Sean on April 06, 2000 12:59 PM
I am quite new to excel but I would like to prevent anybody from taking a Hardcopy of a particular worksheet.
I have put the following code into the before print workbook event and it displays the message OK but then allows printing can anyone help please.
If Activesheet.Name ="Test" Then
MsgBox "this sheet cannot be printed",VbOKOnly,"Non Print Test",0, Cancel = True
end if
I even tried putting in an Application.quit statement after the end if to stop it getting to the print dialog but that did not work.
Am I using this routine correctly? Or is it not possible to prevent printing.
Any Help would be gratefully received
Thanks in advance