Why would I get a Run-time error '462':

The sub-text in the error dialogue says:

The remote server machine does not exist or is unavailable

I am trying to use the Microsoft Word spell-check engine to check the spelling in a user-entry field on a user form in a VBA macro.  It works fine as long as I manually launch Word before running my macro, but it then proceeds to launch a second Word window to do the operation anyway.

The portion of the code where it fails is very simple:

Public swApp As Object

Public mwApp As Object

Sub main()

Set swApp = Application.SldWorks

Set mwApp = Word.Application

UserForm1.Show

End Sub

When it fails, it stops on the line to create the mwApp object.  In other words, it never gets to the UserForm1 code.

Any ideas?

SolidworksApi macros