Export (0) Print
Expand All

IUICommandHandler::UpdateProperty method

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

commandId [in]

Type: UINT32

The ID for the Command, which is specified in the Markup resource file.

key [in]

Type: REFPROPERTYKEY

The Property Key to update.

currentValue [in, optional]

Type: const PROPVARIANT*

A pointer to the current value for key. This parameter can be NULL.

newValue [out]

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

Minimum supported client

Windows 7 [desktop apps only]

Minimum supported server

Windows Server 2008 R2 [desktop apps only]

Product

Windows UI

Header

Uiribbon.h

IDL

Uiribbon.idl

DLL

Mshtml.dll

See also

IUICommandHandler
Windows Ribbon Framework Samples

 

 

Community Additions

ADD
Show:
© 2015 Microsoft