Creating a UI Script
-
From the main menu select Edit/Customize User Interface.
-
In the shortcut menu select the item labeled 'Scripts'. The treeview will now display a list of all the UI scripts.
-
In the treeview, right click the 'Scripts' node and select New/UIScript/LuaUIScript from the context menu and give the new script an appropriate name. This object will run a LUA script when it's invoked.
-
Select the ScriptCode property and click the ... button to show the script editor dialog.
-
Enter the following code into the editor 'print('hello world')' and click the 'OK' button.
-
Now to test out the script, click the Invoke button shown in the script's properties. Notice that 'hello world' was printed in the output pane.
-
To write more useful scripts consult the fragMOTION Type Library for descriptions of all the interfaces supported by the object hierarchy.
Copyright © 2004 Fragmosoft