PDA

View Full Version : Create Cross Reference to Numbered Paragraph in VBA



JohnSW
06-01-2017, 02:34 PM
I'm looking to create a macro that goes to the end of the document, inserted a new section with auto text that has a Heading 3 style that I want to get the reference to and then go to an index table and add cross references in separate table columns to the paragraph number and paragraph text. I can get the paragraph number using Selection.Range.List.List String but it seems cross references using the ReferenceItem to identify the numbered paragraph by default when inserting in VBA. Is there a way to get the ReferenceItem number at the numbered paragraph, convert the paragraph number to a ReferenceItem number, or to create a cross-reference in VBA based on the paragraph number?