View Single Post
 
Old 12-17-2019, 06:48 AM
Marcel Marcel is offline Windows 10 Office 2016
Novice
 
Join Date: Dec 2019
Posts: 2
Marcel is on a distinguished road
Default Word template with Macro keeps getting an error ''Run-time error 5941''

Hi All,

We use a standard template for our engineers so that they can report their activities after a job. Within the template there are several instructions texts and we remove them all by using a simple macro. The macro is hidden within a button.

I have just 1 on more then 100+ engineers with a run-time error. The macro worked fine before when the engineer was running win7, but when he switched to win10 it simply generates the error. We're using office 16.

The error is on this line:

Selection.Find.Style = ActiveDocument.Styles( _
"Subtitle Char;4. Instruction heading Char")

What I simply do not understand is that the macro works perfectly on every computer, but just not on one laptop. I have tried to check all the word settings possible, but no luck. We have re-installed office several times, but no luck.

Hopefully somebody here can help me out.
Thanks in advance!
Reply With Quote