IOleControlSite::GetExtendedControl method

Retrieves an IDispatch pointer to the extended control that the container uses to wrap the real control.

Syntax


HRESULT GetExtendedControl(
  [out] IDispatch **ppDisp
);

Parameters

ppDisp [out]

A pointer to an IDispatch pointer variable that receives the interface pointer to the extended control. If an error occurs, the implementation must set *ppDisp to NULL. On success, the caller is responsible for calling Release when *ppDisp is no longer needed.

Return value

This method can return the standard return values E_OUTOFMEMORY and E_UNEXPECTED, as well as the following values.

Return codeDescription
S_OK

The method completed successfully.

E_NOTIMPL

The container does not implement extended controls.

E_POINTER

The address in ppDisp or *ppDisp is not valid. For example, it may be NULL.

 

Remarks

This method gives the real control access to whatever properties and methods the container maintains in the extended control. These properties and methods would otherwise be inaccessible to the control.

Notes to Callers

The returned pointer is the responsibility of the caller, which must release it when it is no longer needed.

Requirements

Minimum supported client

Windows 2000 Professional [desktop apps only]

Minimum supported server

Windows 2000 Server [desktop apps only]

Header

OCIdl.h

IDL

OCIdl.idl

IID

IID_IOleControlSite is defined as B196B289-BAB4-101A-B69C-00AA00341D07

See also

IOleControlSite

 

 

Show: