Command Execute

The CommandExecute event occurs after a user selects a command from the menu bar or toolbar. You can use this event when you want to execute a set of commands after a particular command is executed. This event takes the Command argument that returns a PivotCommandId constant, which allows you to determine which command the user executed. You can use the Object Browser to view the list of commands for this constant.

The event procedure in Hands-On 24-34 checks whether the user used the Copy command. If the Copy command was executed, the procedure displays a message.

0 0

Post a comment