Share via


CMFCToolBar::ProcessCommand

Posts a WM_COMMAND message to the window that owns the toolbar.

BOOL ProcessCommand(
   CMFCToolBarButton* pButton
);

Parameters

  • [in] pButton
    Pointer to a button on the toolbar.

Return Value

This method should always return TRUE. MFC uses FALSE values internally.

Remarks

This method posts a WM_COMMAND message to the window that owns the toolbar by calling CWnd::PostMessage and passing the command ID of the specified button as the wParam parameter.

Use the ON_COMMAND macro to map the WM_COMMAND message to a member function.

Requirements

Header: afxtoolbar.h

See Also

Reference

CMFCToolBar Class

Hierarchy Chart