Thread: [Solved] Delete specific text
View Single Post
 
Old 01-02-2012, 04:15 AM
macropod's Avatar
macropod macropod is offline Windows 7 64bit Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 22,512
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

Hi Jackson,

Your document still does not use Word's Heading Styles. Did you make the 'MM Topic ' changes I mentioned in my previous post?

The macro does not delete Heading 1-6, or any text associated with them - only Heading 7-9 and the text associated with them.

If you want to preserve Heading 9 and the text associated with it, but not Heading 8 and its text, that makes things much more complicated for the macro. What you could do is to:
1: add ', "Heading 9"' to the 'Case' statement; and
2. run the macro twice, the first time with '.Style = "Heading 8"' and the second time with '.Style = "Heading 7"'.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote