BCGControlBar Pro for MFC
CBCGPToolbarButton* CBCGPToolBar::GetButtonByCommand ( UINT  uiCmd) const

Given an command ID returns a toolbar button.

Returns
A pointer to the toolbar button if success; its is NULL if the button with the specified command ID does not exist.

Use this function to obtain a pointer to a toolbar's button by the command ID.

Parameters
uiCmdSpecifies the command ID of the button to return.