This event is fired when the associated control is manipulated by the user. A new Command object is created and passed back through this event which you can then use to interact with the user to get any input the command requires.
-------- 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::CommandCreatedEventHandler { public: void notify(const Ptr<CommandCreatedEventArgs>& eventArgs) override { // Code to react to the event. ui->messageBox("In MyCommandCreatedEventHandler event handler."); } } _commandCreated; --------- Connect the handler to the event. ---------
|
Name | Description |
Command Inputs API Sample | Creates a command dialog that demonstrates all of the available command inputs. To use the sample, create a new Python or C++ script and copy and paste this code, replacing the default code. You also need to unpack this zip file which contains a resource folder into the same folder where the source code file (.py or .cpp) is. |