IUICommandHandler::UpdateProperty method (uiribbon.h)
Responds to property update requests from the Windows Ribbon framework.
Syntax
HRESULT UpdateProperty(
[in] UINT32 commandId,
[in] REFPROPERTYKEY key,
[in, optional] const PROPVARIANT *currentValue,
[out] PROPVARIANT *newValue
);
Parameters
[in] commandId
Type: UINT32
The ID for the Command, which is specified in the Markup resource file.
[in] key
Type: REFPROPERTYKEY
The Property Key to update.
[in, optional] currentValue
Type: const PROPVARIANT*
A pointer to the current value for key. This parameter can be NULL.
[out] newValue
Type: PROPVARIANT*
When this method returns, contains a pointer to the new value for key.
Return value
Type: HRESULT
If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.
Remarks
This method should be allowed to return before any subsequent calls to the Ribbon framework are made.
The values of Command properties, such as UI_PKEY_Enabled or UI_PKEY_Label, are set through calls to SetUICommandProperty or InvalidateUICommand.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows 7 [desktop apps only] |
Minimum supported server | Windows Server 2008 R2 [desktop apps only] |
Target Platform | Windows |
Header | uiribbon.h |
DLL | Mshtml.dll |