Hi,
I have an Access 97 application that exports data to a MS Word template.
Using Windows XP this code works fine, I have recently attempted to run this code on a Windows 7 machine and it fails with the error..
Run Time Error '5981'
Could not open macro storage.
I have tried making the user a full admin on the machine but this has had no effect.
Below is the code that is failing..
It fails when it hits the .Documents.add line.
So far I haven't had any luck in getting the current code to run, if anyone can suggest an alternative way of producing the document then I am open to idea's.
I have an Access 97 application that exports data to a MS Word template.
Using Windows XP this code works fine, I have recently attempted to run this code on a Windows 7 machine and it fails with the error..
Run Time Error '5981'
Could not open macro storage.
I have tried making the user a full admin on the machine but this has had no effect.
Below is the code that is failing..
Code:
Set WdApp = CreateObject("Word.Application")
With WdApp
'Open new file based on template.
.Documents.add (Template_Path & "Invoice.dot")
It fails when it hits the .Documents.add line.
So far I haven't had any luck in getting the current code to run, if anyone can suggest an alternative way of producing the document then I am open to idea's.