Hello,
As per captioned title, I have encountered "Compile Error: User-defined type not defined" when running the below line with VBA in excel.
Dim WordApp As Word.Application
However, I have already added a reference to the word library (Tools>Rerefences>Microsoft Word 16.0 Object Library).
What else can i do to fix the error?
Many thanks!