Software & Finance

C# - Step 5.5 ClassInterfaceType.AutoDispatch


ClassInterfaceType.AutoDispatch (for dispinterface for the class used in late binding for COM Client)


When you use ClassInterfaceType.AutoDispatch like below





the following code will get generated on C++ client side with #import tlb file.



struct __declspec(uuid("43b9838e-b01d-42df-aa8e-3c6a7a27f578"))

/* LIBID */ __SFTCSServer;

struct __declspec(uuid("12d1edac-20c0-4faa-a774-b6f4c300b47e"))

/* dispinterface */ IMathCtrl;

struct /* coclass */ MathCtrl;

struct __declspec(uuid("a494592f-20ab-3552-9489-c40f8abfe342"))

/* dual interface */ _MathCtrl;



_COM_SMARTPTR_TYPEDEF(IMathCtrl, __uuidof(IMathCtrl));

_COM_SMARTPTR_TYPEDEF(_MathCtrl, __uuidof(_MathCtrl));


struct __declspec(uuid("a494592f-20ab-3552-9489-c40f8abfe342"))

_MathCtrl : IDispatch



Back to Index of Steps for C# class Library Server and C++ Index


Click here to download the complete source code of C# Class Library Server and C++ Client