ESPO: Method ambiguity

I found the answer here . However, I cannot find _Application or _Document with reference to Microsoft.Office.Interop.Word. I did using Word = Microsoft.Office.Interop.Word;, then I tried to find _Document and _Application, but all I can find is Document and Application. I believe the Document interface inherited _Document and DocumentEvents2. Does anyone know how to solve this annoying warning? edit: this is for Office 2010 and I am using Interop.Word version 14

+3
source share
1 answer

The word is not my area, but in general this message appears when the interface (Word) implements two interfaces, each of which has a similarly called method. To avoid a warning, you need to specify the specific interface that interests you.
There is an illustration with Worksheet.Activate () (equivalent problem in Excel) here .

0
source

All Articles