The commandCreated event fires immediately after the command is created.
-------- Import ----------------- Global variables --------- -------- Connect the handler to the event. --------- -------- Event handler function definition --------- |
-------- Global variables ----------------- Connect the handler to the event. --------- -------- Event handler class definition --------- |
--------- Required include files. ------------------ Event handler class definition and global declaration. --------- class MyCommandCreatedEventHandler : public adsk::core::ApplicationCommandEventHandler { public: void notify(const Ptr<ApplicationCommandEventArgs>& eventArgs) override { // Code to react to the event. ui->messageBox("In MyCommandCreatedEventHandler event handler."); } } _commandCreated; --------- Connect the handler to the event. --------- |