COleDispatchDriver::DetachDispatch
分离此对象的当前 IDispatch 连接。
LPDISPATCH DetachDispatch( );
返回值
对以前附加的OLE IDispatch 对象的指针。
备注
不释放 IDispatch。
有关 LPDISPATCH 类型的更多信息,请参见。Windows SDK的 Implementing the IDispatch Interface。
示例
LPDISPATCH CreateLPDispatch(LPCTSTR lpszProgId)
{
COleDispatchDriver disp;
disp.CreateDispatch(lpszProgId);
return disp.DetachDispatch();
}
要求
Header: afxdisp.h
请参见
参考
COleDispatchDriver::ReleaseDispatch
COleDispatchDriver::CreateDispatch