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
"xlcharlie" wrote in
message
...
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.