BCGControlBar Pro for MFC
CBCGPUserTool* CBCGPUserToolsManager::CreateNewTool ( )

Creates a new user tool.

A pointer to the newly created user tool. It is NULL if the number of user tools has exceeded the maximum.

Call this member function to create a new user tool. This function will find a first available menu command ID within a supplied in the constructor of CBCGPUserToolsManager range and assign the user tool this ID.

The function fails if the maximal number of tools has been reached. You can retrieve this number by calling GetMaxTools(). You can get access to the tools list by calling the GetUserTools() function.