- Joined
- Feb 19, 2020
- Messages
- 2
- Reaction score
- 0
I am trying to figure out a macro to split the document by heading regardless of the heading level into separate documents for an audiobook.
sub selectHeadingAndContent
Selection.GoTo What:=wdGoToHeading, Which:=1 'this is the start of the selection
Selection.GoToNext (wdGoToHeading) 'this is the end of the selection.
end sub
I'm trying to put these 2 positions into a range object so that I can copy the range.
if anyone can please help me figure this range bit out I'd surely appreciate it.
Thanks!
Desert_dweller5
sub selectHeadingAndContent
Selection.GoTo What:=wdGoToHeading, Which:=1 'this is the start of the selection
Selection.GoToNext (wdGoToHeading) 'this is the end of the selection.
end sub
I'm trying to put these 2 positions into a range object so that I can copy the range.
if anyone can please help me figure this range bit out I'd surely appreciate it.
Thanks!
Desert_dweller5