Key Scripts

Cognex Designer Key Scripts are scripts that are executed when a specific key combination is pressed.

  1. To create a new script, under the Scripting node of the Project Explorer, right-click on the Key Scripts node and select New Script.

  2. Select the specific key combination that the script should execute on, and then press the Accept button.

  3. In the Script Editor, enter the code you want to execute and once the script successfully compiles, press the Save icon.