hindersaliva
asked on
Word VBA - filling an Array with content of an Outline
In Excel I can fill an Array with the contents of a Range, like this.
If I want to do similar in Word with VBA, where I want to fill an Array with the text that are in an outline with styles Heading 1, 2, and 3, I have been using Find (by style). That works, but takes up to 30 seconds on a document that has 1,000 approx headings.
Is there an equivalent in Word with VBA that works the same way as in Excel? ie. Instantaneously populating an Array with the contents of an Outline.
Thanks
arrMyArray = Range("A1:M1000")
It is quick. Instantaneous.If I want to do similar in Word with VBA, where I want to fill an Array with the text that are in an outline with styles Heading 1, 2, and 3, I have been using Find (by style). That works, but takes up to 30 seconds on a document that has 1,000 approx headings.
Is there an equivalent in Word with VBA that works the same way as in Excel? ie. Instantaneously populating an Array with the contents of an Outline.
Thanks
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.