TranslateMenuMessage method
Collapse the table of content
Expand the table of content

IMenuBand::TranslateMenuMessage method

Translates a message for a Component Object Model (COM) object.

Syntax


HRESULT TranslateMenuMessage(
  [in, out] MSG     *pmsg,
  [out]     LRESULT *plRet
);

Parameters

pmsg [in, out]

Type: MSG*

A pointer to an MSG structure that contains the incoming message.

plRet [out]

Type: LRESULT*

A pointer to the translated message.

Return value

Type: HRESULT

This method can return one of these values.

Return codeDescription
S_OK

The message was handled and should be deleted.

S_FALSE

The message was not handled. In this case, *plRet is NULL.

 

Remarks

Typically, IMenuBand::IsMenuMessage is called before this method. The parent window proc, not the message pump, must call IMenuBand::TranslateMenuMessage for every message.

This method can change the values of pmsg. If so, the changes should be forwarded on.

This method is required because some modal message pumps do not allow a call to a custom translation method.

Requirements

Minimum supported client

Windows XP [desktop apps only]

Minimum supported server

Windows Server 2003 [desktop apps only]

Header

Shobjidl.h

IDL

Shobjidl.idl

DLL

Shell32.dll

 

 

Show:
© 2016 Microsoft