IActiveDesigner::GetRuntimeMiscStatusFlags

Returns the miscellaneous status flags for the run-time object.

HRESULT GetRuntimeMiscStatusFlags (
DWORD *dwMiscFlags
);

Parameter

dwMiscFlags

[out] Pointer to the miscellaneous status flags. The flags have the following meanings:

Flag

Meaning

OLEMISC_ACTSLIKEBUTTON

The container is prepared to act like a button. Typically used by containers that provide Default and Cancel buttons.

OLEMISC_ACTSLIKELABEL

ActiveX objects can change the container's preset label.

OLEMISC_ALIGNABLE

The container supports aligned controls.

OLEMISC_ALWAYSRUN

The object should be put into the run state even if it is not visible. Not normally used by in-process servers, including ActiveX designers.

OLEMISC_IMEMODE

The object understands IME mode. Used only by double-byte character set (DBCS) applications.

OLEMISC_INVISIBLEATRUNTIME

The object is visible only at design time. Used by ActiveX designer objects that are invisible at run time.

OLEMISC_NOUIACTIVATE

The object does not support user interface activation.

OLEMISC_SETCLIENTSITEFIRST

The object requires status information from IOleControl::SetClientSite immediately after creation, rather than after a call to IPersistStorage::Load or IPersistStorage::InitNew.

OLEMISC_SIMPLEFRAME

The object supports the ISimpleFrameSite protocol.


Return Values

The return value obtained from HRESULT is one of the following:

Return Value

Meaning

S_OK

Success.

E_FAIL

The method failed for an unknown reason.

E_NOTIMPL

The design-time and and run-time objects are the same.


Comments

ActiveX designers should return all the status flags that appear in the registry for the run-time object. For more information, see the  COM Programmer's Reference.

Example

The following example stores the flag values in the constant RUNTIME_MISCSTATUS and simply returns its value to the caller:

STDMETHODIMP CMyDesigner::GetRuntimeMiscStatusFlags
(
    DWORD *pdwMiscStatus
)
{
    CHECK_POINTER(pdwMiscStatus);

    *pdwMiscStatus = RUNTIME_MISCSTATUS;
    return S_OK;
}