Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 56
Default Hiding cell values for printing

I have an excel sheet that I use for accounting and I make a shop copy for
workers to build from. I have a BeforePrint procedure that lets the user
determine if the printing is for a "shop copy" or "office copy". I currently
have script that erases or inserts dollar values in certain cells depending
on which copy is selected. (Shop-no values, office-dollar values). My issue
is that I would like the sheet to end up with the values it had prior to
printing. I could not find any info in the help file on an AfterPrint sub. I
tried to do a print area alteration for each copy but the cells that need to
be hidden are in the middle of the sheet and the print area then split the
single sheet into 2 printed sheet. Does anyone have any suggestions on how to
do this? Any help would be appreciated.
  #2   Report Post  
Posted to microsoft.public.excel.programming
ben ben is offline
external usenet poster
 
Posts: 232
Default Hiding cell values for printing

Jcanyoneer,


workbook_beforeprint(cancel as boolean)
application.enableevents = false
cancel = true
'enter code here to choose and place desired values'
activesheet.printout 'you can lookup printout in help to see all the
setting you can change
'enter code here to replace values with originals
application.enableevents = true
end sub





"JCanyoneer" wrote:

I have an excel sheet that I use for accounting and I make a shop copy for
workers to build from. I have a BeforePrint procedure that lets the user
determine if the printing is for a "shop copy" or "office copy". I currently
have script that erases or inserts dollar values in certain cells depending
on which copy is selected. (Shop-no values, office-dollar values). My issue
is that I would like the sheet to end up with the values it had prior to
printing. I could not find any info in the help file on an AfterPrint sub. I
tried to do a print area alteration for each copy but the cells that need to
be hidden are in the middle of the sheet and the print area then split the
single sheet into 2 printed sheet. Does anyone have any suggestions on how to
do this? Any help would be appreciated.

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 56
Default Hiding cell values for printing

Kinda simple when you know the stuff, huh! Thank you. it works perfect!

"ben" wrote:

Jcanyoneer,


workbook_beforeprint(cancel as boolean)
application.enableevents = false
cancel = true
'enter code here to choose and place desired values'
activesheet.printout 'you can lookup printout in help to see all the
setting you can change
'enter code here to replace values with originals
application.enableevents = true
end sub





"JCanyoneer" wrote:

I have an excel sheet that I use for accounting and I make a shop copy for
workers to build from. I have a BeforePrint procedure that lets the user
determine if the printing is for a "shop copy" or "office copy". I currently
have script that erases or inserts dollar values in certain cells depending
on which copy is selected. (Shop-no values, office-dollar values). My issue
is that I would like the sheet to end up with the values it had prior to
printing. I could not find any info in the help file on an AfterPrint sub. I
tried to do a print area alteration for each copy but the cells that need to
be hidden are in the middle of the sheet and the print area then split the
single sheet into 2 printed sheet. Does anyone have any suggestions on how to
do this? Any help would be appreciated.

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
How do I suppress printing a row without hiding it? ejt1234 Excel Discussion (Misc queries) 5 October 27th 07 03:23 AM
Hiding Rows when printing pano Excel Worksheet Functions 1 February 23rd 07 01:13 PM
hiding then printing a row S S Excel Worksheet Functions 4 August 9th 06 09:56 PM
hiding individual cell values when printing Glen Excel Discussion (Misc queries) 7 July 26th 06 12:03 AM
Hiding rows when printing DHallam Excel Discussion (Misc queries) 1 May 21st 06 11:30 AM


All times are GMT +1. The time now is 02:36 AM.

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

About Us

"It's about Microsoft Excel"