Share via


COleDispatchDriver::DetachDispatch

Rimuove la connessione corrente IDispatch da questo oggetto.

LPDISPATCH DetachDispatch( );

Valore restituito

Un puntatore all'oggetto precedentemente allegato OLE IDispatch.

Note

IDispatch non viene rilasciato.

Per ulteriori informazioni sul tipo LPDISPATCH, vedere Implementing the IDispatch Interface in Windows SDK.

Esempio

LPDISPATCH CreateLPDispatch(LPCTSTR lpszProgId)
{
    COleDispatchDriver disp;

    disp.CreateDispatch(lpszProgId);

    return disp.DetachDispatch();
}

Requisiti

Header: afxdisp.h

Vedere anche

Riferimenti

Classe di COleDispatchDriver

Grafico della gerarchia

COleDispatchDriver::ReleaseDispatch

COleDispatchDriver::CreateDispatch

COleDispatchDriver::AttachDispatch

COleDispatchDriver::m_lpDispatch