search and replace with a paga break

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Has anybody got a clue how I can record a search and replace macro which inserts a page break at certain results
Recording it doesn't seem to work. Maybe a visual basic example

Thanks in advance

Emiel, Holland
 
I think you'll have to break it down into pieces--since replace does the
replacement all at once.

Record a macro when you do:
Edit|replace
then
Edit|find
then
Insert|PageBreak.

There's an example in VBA's help on how to find the first one and keep track of
its position--so you know when to quit.

(I wasn't sure what "certain results" meant--for each replacement or just a
subset???).

Post back with your code if you have trouble.
 
Back
Top