Disable Printing

  • Thread starter Thread starter JOHN SMITH
  • Start date Start date
J

JOHN SMITH

Hi,

I have a sheet that i need to be save it before it can be printing.

can we disable print? until the sheet has been saved it?

I have a nice button/macro that save, send and print the data on
this sheet but the user can print it anyways.

thnks
 
Private Sub Workbook_BeforePrint(Cancel As Boolean)
MsgBox "Must Save Sheet!!!!"
Cancel = True
End Sub

thnks
 
Something like...

Option Explicit
Private Sub Workbook_BeforePrint(Cancel As Boolean)
If Me.Saved Then
'do nothing
Else
MsgBox "Must Save Workbook!!!!"
Cancel = True
End If
End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top