Export (0) Print
Expand All

CCmdTarget::GetIDispatch 

Call this member function to retrieve the IDispatch pointer from an automation method that either returns an IDispatch pointer or takes an IDispatch pointer by reference.


LPDISPATCH GetIDispatch(
   BOOL bAddRef 
);

Parameters

bAddRef

Specifies whether to increment the reference count for the object.

The IDispatch pointer associated with the object.

For objects that call EnableAutomation in their constructors, making them automation enabled, this function returns a pointer to the Foundation Class implementation of IDispatch that is used by clients who communicate via the IDispatch interface. Calling this function automatically adds a reference to the pointer, so it is not necessary to make a call to IUnknown::AddRef.

Community Additions

ADD
Show:
© 2014 Microsoft