Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 23
Default prevent page printout

Hello

I have been looking in the variabel list to find a variable that
prevent printing out a sheet.

If there isn't any variable to prevent this, does anyone have a good
Idea to prevent print out a sheet???

Anyone know about this

Regards

Kurt

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 67
Default prevent page printout

Hello
You can try this workbook event:
Private Sub Workbook_BeforePrint(Cancel As Boolean)
If ActiveSheet.Name = "Sheet1" Then Cancel = True
End Sub

HTH
Cordially
Pascal


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,302
Default prevent page printout

Hi Kurt,

Try:

'=============
Private Sub Workbook_BeforePrint(Cancel As Boolean)
Cancel = ActiveSheet.Name = "Sheet1" '<<==== CHANGE
End Sub
'<<=============

This is workbook event code and should be pasted into the workbook's
ThisWorkbook module *not* a standard module or a sheet module:

Right-click the Excel icon on the worksheet
(or the icon to the left of the File menu if your workbook is maximised)

Select 'View Code' from the menu and paste the code.

Alt-F11 to return to Excel.

---
Regards,
Norman



"kurt" wrote in message
oups.com...
Hello

I have been looking in the variabel list to find a variable that
prevent printing out a sheet.

If there isn't any variable to prevent this, does anyone have a good
Idea to prevent print out a sheet???

Anyone know about this

Regards

Kurt



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
suppressing a footer only on the first page of a printout Paul James Excel Discussion (Misc queries) 4 January 26th 05 06:26 AM
suppressing a footer only on the first page of a printout Paul James[_3_] Excel Programming 6 January 26th 05 06:26 AM
suppressing a footer on the first page of a printout Paul James Excel Discussion (Misc queries) 1 January 25th 05 11:57 PM
suppressing a footer on the first page of a printout Paul James[_3_] Excel Programming 1 January 25th 05 11:57 PM
ActiveSheet.Printout or Page Setup? Michelle Excel Programming 0 April 23rd 04 03:55 PM


All times are GMT +1. The time now is 10:12 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"