View Single Post
 
Old 02-14-2016, 03:35 AM
macropod's Avatar
macropod macropod is online now Windows 7 64bit Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 22,382
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

Rocky2: Please don't ask the same question in multiple threads. I've merged the two threads concerned.

Section numbers returned by .Information(wdActiveEndSectionNumber) will be correct. whether you're Set secTemp = ActiveDocument.Sections(sectionNum) is 'correct' depends on what you're referencing for .Information(wdActiveEndSectionNumber). Since you haven't posted the relevant code, or said what you're expecting, there's know way for anyone here to know one way or the other.

Why do you want to check the character before the Heading? Graham has already given you robust code that works for all headers, regardless of whether the preceding character is a Section break.

FWIW, Section breaks & page breaks have an ASCII value of 12, whilst column breaks have an ASCII value of 14.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote