You don't, C# will do that for you automatically creating prodids {1...n}.
However there may be times when a property or method must match a well-known
progid in the COM world so in this case you would need to specifiy it. You
may not encounter this scenario. Some examples are ActiveX controls well
known properties or Ole Collections.
The only time I have found where I needed to was on a COM event source
interface written in c#.
--
Cheers,
Micky D
"Daniel Lidström" <someone (AT) microsoft (DOT) com> wrote
Quote:
Hello!
I've read on MSDN [1] that it is necessary to mark methods and properties
with DispId in order to expose them to COM. But that doesn't seem
necessary. I've created interfaces and subclasses in C# and I have no
problem using them from C++. So what is DispId really used for?
[1] Example COM Class (C#): http://msdn2.microsoft.com/en-us/lib...20(VS.80).aspx
--
Daniel |