how to use ATL with universal marshaler instead of MIDL?
when do we use universal marshaler and when MIDL? and examples.
Printable View
how to use ATL with universal marshaler instead of MIDL?
when do we use universal marshaler and when MIDL? and examples.
Hi,
Add the 'oleautomation' attribute to the interface declaration in the idl file and be sure to call RegisterTypeLIb API which will add some entries in teh registry which links ur COM object with teh universal marshaller.
e.g
[
oleautomation,
object,
uuid(5BAD0B0E-0000-0000-C000-000000000046)
]
interface IYourInterface : IUnknown
{
HRESULT YourMethod([in] long n);
}