#1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default page break

Is it possible for a macro to find a word in the cell and
use it as it end point for page break? I will like to
have a page break on every cell that have the
word "Sales grand total". Thanks in advance
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default page break

Turn on the macro recorder

do edit=find
type in
Sales grand total

when it is found, do Insert=PageBreak

Turn off the macro recorder. Adapt the recorded code to your needs.

Note that if the cells are farther apart than what can fit on a page, that
you may not get the results you expect. This only works if the distance can
be contained on an entire page.

--
Regards,
Tom Ogilvy

mike wrote in message
...
Is it possible for a macro to find a word in the cell and
use it as it end point for page break? I will like to
have a page break on every cell that have the
word "Sales grand total". Thanks in advance



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
Excel 2007 Page Break Adjustments causes a page break each cell BKaufman Excel Worksheet Functions 2 September 10th 10 05:02 AM
How do I do page breaks when view menu doesnt page break preview HeatherF55 Excel Discussion (Misc queries) 0 September 21st 07 04:24 AM
change page number watermark in page break preview juga Excel Discussion (Misc queries) 2 December 25th 06 10:16 AM
change and/or remove page number watermark in page break preview juga Excel Discussion (Misc queries) 2 December 25th 06 10:15 AM
adding a new page break to an existing page break Edward Letendre Excel Discussion (Misc queries) 1 March 6th 05 09:29 AM


All times are GMT +1. The time now is 01:29 PM.

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"