Home |
Search |
Today's Posts |
#1
|
|||
|
|||
How do I write a macro to find, select, and then delete a Section.
I have a document in Word that is a form to fill out with instructions. I've
placed all the instructions in the same section, separate from the form. I want a macro that will go bact to the Instructions section, and then delete that section, so what is left is the one page form. anyone write a macro like that? Thanks! |
#2
|
|||
|
|||
Hi nw_nick
Try something like this: ActiveDocument.Sections(1).Range.Delete For testing, make a backup of your document before you begin! Hope this helps. Shauna Kelly. Microsoft MVP. http://www.shaunakelly.com/word "nw_nick" wrote in message ... I have a document in Word that is a form to fill out with instructions. I've placed all the instructions in the same section, separate from the form. I want a macro that will go bact to the Instructions section, and then delete that section, so what is left is the one page form. anyone write a macro like that? Thanks! |
#3
|
|||
|
|||
Shauna:
You're a genius! That is exactly what I needed and it works perfectly! Thank you very much Nick "Shauna Kelly" wrote: Hi nw_nick Try something like this: ActiveDocument.Sections(1).Range.Delete For testing, make a backup of your document before you begin! Hope this helps. Shauna Kelly. Microsoft MVP. http://www.shaunakelly.com/word "nw_nick" wrote in message ... I have a document in Word that is a form to fill out with instructions. I've placed all the instructions in the same section, separate from the form. I want a macro that will go bact to the Instructions section, and then delete that section, so what is left is the one page form. anyone write a macro like that? Thanks! |