AnsweredAssumed Answered

Which imports and references to use?

Question asked by Eric Snyder on Jun 15, 2018
Latest reply on Jun 18, 2018 by Eric Snyder

Using Visual Studio 2017.

 

There are all kinds of examples in the 2018 help files. A big problem with them is they are not complete. They do not show all the references that need to be added or imports that are needed. My problem is finding what references to add and what to import. An example:

 

swPart = swApp.OpenDoc6(fileName, swDocumentTypes_e.swDocPART, swOpenDocOptions_e.swOpenDocOptions_Silent, "", errors, warnings)

I am getting errors on both swDocumentTypes and swOpenDocOptions:

 

swDocumentTypes_e.swDocPART is not declared. It may be inaccessable due to it's protection level.

 

What is the best way to determine the references I need to add and the imports that need to be added?

Outcomes