Skip to content
Anthony Headley edited this page May 5, 2021 · 3 revisions

Cmd(string:command, [object:undo]) : string

Brief:

Enters a command on the command line with an optional undo object. Using Cmd() will cause the command to execute from the context of the lua script. In many cases this will function correctly, however if you have issues or your command will call the UI then use CmdIndirect instead.

Parameters:

Name Description Optional
string:command A command line string
object:undo An Undo session Object

Returns:

string: "Ok" string: "Syntax Error" string: "Illegal Command" ...

Examples:

Cmd("Fixture 1 thru 36")
local undo = CreateUndo()
Cmd("Store Cue 1", undo)
CloseUndo(undo)
Clone this wiki locally