BCGControlBar Pro for MFC
void CBCGPRibbonBar::GetElementsByID ( UINT  uiCmdID,
CArray< CBCGPBaseRibbonElement *, CBCGPBaseRibbonElement * > &  arButtons,
BOOL  bIncludeFloaty = FALSE 
)

Returns an array of all elements with specified ID.

Fills arButtons with pointers to all elements with specified command ID. Ribbon bar may contain several elements with the same command ID, because some elements can be copied and placed on Quick Access Toolbar.

Parameters
uiCmdIDSpecifies command ID to search by.
arButtonsWhen the function returns, the array contains pointers to ribbon elements that have been found.
bIncludeFloatyWhen this parameter is TRUE, the array also includes elements located on the mini-toolbar (floaty).