Selecting Primary Header of Section 8

Z

zSplash

I have a document with multiple sections, and I want to select the Primary
Header of Section 8. The code I used to select the first section was:
ActiveDocument.StoryRanges(wdPrimaryHeaderStory).Select
How can I select the Primary Header of Section 8, in a similar fashion?

TIA
 
S

Shauna Kelly

Hi zSplash

ActiveDocument.Sections(8).Headers(wdHeaderFooterPrimary).Range.Select

You may find it useful to re-do your present code to refer to Section 1
explicitly, in the same way as the line above.

Hope this helps.

Shauna Kelly. Microsoft MVP.
http://www.shaunakelly.com/word
Melbourne, Australia
 
Z

zSplash

Thank you, Shauna. Outstanding!

st.

Shauna Kelly said:
Hi zSplash

ActiveDocument.Sections(8).Headers(wdHeaderFooterPrimary).Range.Select

You may find it useful to re-do your present code to refer to Section 1
explicitly, in the same way as the line above.

Hope this helps.

Shauna Kelly. Microsoft MVP.
http://www.shaunakelly.com/word
Melbourne, Australia
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top