API 文档 > Creo Parametric user interface > Object ProMenubarmenu > Function ProMenubarmenuChkbuttonAdd
Function ProMenubarmenuChkbuttonAdd
DEPRECATED:
Since Creo 1
SUPERSEDED BY:
Description
Note: This API is deprecated. Use ProCmdDesignate() to designate a check button and Customize UI dialog to add it in Creo Parametric Ribbon UI.
Adds a new check button to the menu of Creo Parametric.
This function affects the top-level Creo Parametric menu bar only.
This function is executed only once during a Creo Parametric session for each action. Subsequent calls to this function for a previously loaded check button are ignored.
Note:
To find the name of an existing item to use as a neighbor, select that item in Creo Parametric and look at your trail file.
Synopsis
#include <ProMenuBar.h>
ProMenubarmenuChkbuttonAdd
(
ProMenuItemName parent_menu
/* (In)
The name of the parent menu
*/
ProMenuItemName check_button_name
/* (In)
The name of the check button (must be unique)
*/
ProMenuItemLabel check_button_label
/* (In)
The label of the check button
*/
ProMenuLineHelp one_line_help
/* (In)
The one-line help for the menu
*/
/* (In)
The neighbor item in the parent menu.
Note: If you are adding the first item to a new menu (created using either ProMenubarMenuAdd() or ProMenubarmenuMenuAdd()), set the neighbor argument to NULL.
*/
ProBoolean add_after_neighbor
/* (In)
Defines whether to add the checkbutton before or after the neighbor item; PRO_B_TRUE specifies after.
*/
uiCmdCmdId option_id
/* (In)
The identifier of the option attached to the check button
*/
ProFileName filename
/* (In)
The name of the message file that contains the label and help string
*/
)
Returns
The function successfully added a check button.
The specified message was not found in the message file.
a menubar entity with this name already exists.
The function failed to add a check button.
Sample Code References
User Guide References
这对您有帮助吗?