print event

X

xlcharlie

I want my beforeprint event code to execute only when the user prints the
document, not when the user switches to print preview. I tried creating a
button that would call a procedure to disable events, switch to print
preview, then re-enable events, but the user can then print from print
preview without executing the code for the beforeprint event.
 
C

Chip Pearson

The BeforePrint is rather anemic; it doesn't tell you what is
being printed (a range, a sheet, or a workbook) and doesn't
distinguish between printing and print preview. I don't think
there is any solid way to do what you want.


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com


message
news:[email protected]...
 

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

Top