Hello,
I am currently struggling with a small automation process. I hope you can help me and thanks in advance for that.
I have a long list of word files in a specific folder.
Each file has a header, which contains a picture and a line of text (the title) surrounded by a border.
I would like to write an Excel VBA script that opens the word files one by one, extract their headers (i.e. the title), and lists them in the excel file.
Here is what I already have:
The word documents open correctly, but I receive an error message on this statement:
=> Run-time error '438': Object doesn't support this property or method.
So I am stuck there. I have tried several improvements but did not manage to do better.
I would like to debug this and be able to retrieve the text contained in the header, and then to paste it in my Excel sheet.
Would anyone of you be so kind to help me?
Thanks a lot in advance.
Bookmarks