Output Commands

ADD LABEL
BUTTON COLOR
BUTTON OPACITY
BUTTON STATE
MOVE BUTTON BACK
MOVE BUTTON FRONT
OUTPUT COLOR
PUSH BUTTON
PUSH BUTTON DOWN
PUSH BUTTON DOWN WITH DELAY
PUSH BUTTON UP
PUSH BUTTON UP WITH DELAY
RENAME
RENAME GROUP
SEND
SEND BUTTON COLOR
SEND TEXT COLOR
TEXT COLOR


ADD LABEL

Adds a label to the current code. Returns 1 if successful. Returns 0 if no label was added

Format: ADD LABEL [label_name] WITH ID [tracking_id]

Arguments: label_name: The name of the label you wish to add to all the currently selected code buttons tracking_id: A string representing this operation so that duplicates do not get added. Only the first label for each tracking_id for each code will be added.

Available: Available for code windows Version: 9 and later

Example: 

ADD LABEL $score with id “myScore”
Adds the value stored in the $score variable to the current code. Adding the label $score will occur before the code is added to timeline. If the scripts get executed again no labels with the ID “myScore” will be added to the same code


BUTTON COLOR

Changes the background color of the current button

Format: BUTTON COLOR ( red_color , green_color , blue_color ) OR BUTTON COLOR ( red_color , green_color , blue_color , alpha_level) OR BUTTON COLOR button_name

Arguments: color: a red, green or blue color value 0->100 alpha: color alpha with a value 0->100. 100 no transparency in the color button_name: a string with the name of a button

Available: Available for code windows Version: 9 and later. alpha_level available in 9.2

Example: 

BUTTON COLOR (100,0,0)
Changes the background color of the current button to red 

BUTTON COLOR “legend”
Changes the background color of the current button to that from the button named “legend” in the same window


BUTTON OPACITY

Changes the opacity of the current button

Format: BUTTON OPACITY opacity_level

Arguments: opacity_level: an opacity value 0->100. 0 will make the button invisible

Available: Available for code windows Version: 9 and later

Example: 

BUTTON OPACITY 50
Changes the button to half transparency


BUTTON STATE

Returns 1 if button is down and 0 if button is up, in the code input window.

Format: BUTTON button_name STATE OR BUTTON button_name STATE IN WINDOW window_name

Arguments: button_name: a string with the name of a button in the code input window window_name: the name of the code input window

Available: Available for all windows Version: 9 and later

Example: 

SHOW BUTTON “name1” STATE
Shows 0 or 1 depending on if the button is up or down 

IF (BUTTON “name1” STATE IN WINDOW “window1”, SHOWDOWN”, SHOWUP”)
Show up/down depending on if the button “name1” is up or down in the code input window with title “window1”


MOVE BUTTON BACK

Moves the button to the back of the code window

Format: MOVE BUTTON BACK

Arguments:

Available: Available for code windows Version: 9.3 and later

Example:

MOVE BUTTON BACK
Moves this button to the back of the code window


MOVE BUTTON FRONT

Moves the button to the front of the code window

Format: MOVE BUTTON FRONT

Arguments:

Available: Available for code windows Version: 9.3 and later

Example:

MOVE BUTTON FRONT
Moves this button to the front of the code window


OUTPUT COLOR

Changes the text color for the output of the button

Format: OUTPUT COLOR ( red_color , green_color , blue_color )

Arguments: color: a red, green or blue color value 0->100

Available: Available for code windows Version: 9 and later

Example:

OUTPUT COLOR (100,0,0)
Changes the output color of the text to red


PUSH BUTTON

Pushes the button up/down in the code input window. If this is a label button then you only need to use DOWN

Format: PUSH BUTTON button_name DOWN OR PUSH BUTTON button_name UP OR PUSH BUTTON button_name DOWN IN WINDOW window_name OR PUSH BUTTON button_name UP IN WINDOW window_name

Arguments: button_name: a string with the name of a button in the code input window window_name: the name of the code input window

Available: Available for spreadsheet windows Version: 9 and later

Example:

PUSH BUTTON “name1” DOWN
Pushes the button “name1” down in the front code input window 

PUSH BUTTON “name1” UP IN WINDOW “window1”
Pushes the button “name1” up in the code input window with title “window1”


PUSH BUTTON DOWN

Pushes the button down

Format: PUSH BUTTON DOWN

Arguments:

Available: Available for code windows Version: 9 and later

Example:

PUSH BUTTON DOWN
Pushes the current button down


PUSH BUTTON DOWN WITH DELAY

Pushes the button down after a delay

Format: PUSH BUTTON DOWN WITH DELAY delay

Arguments: delay: delay in seconds between 0 and 10

Available: Available for code windows Version: 9 and later

Example:

PUSH BUTTON DOWN WITH DELAY 0.2
Pushes the current button down in 0.2 seconds time


PUSH BUTTON UP

Pushes the button up

Format: PUSH BUTTON UP

Arguments:

Available: Available for code windows Version: 9 and later

Example:

PUSH BUTTON UP
Pushes the current button up


PUSH BUTTON UP WITH DELAY

Pushes the button up after a delay

Format: PUSH BUTTON UP WITH DELAY delay

Arguments: delay: delay in seconds between 0 and 10

Available: Available for code windows Version: 9 and later

Example:

PUSH BUTTON UP WITH DELAY 0.2
Pushes the current button up in 0.2 seconds time


RENAME

Renames the current button

Format: RENAME new_button_name

Arguments: new_button_name: a string containing the new button name

Available: Available for code windows Version: 9 and later

Example:

RENAME “new name”
Changes the name of the current button to “new name”


RENAME GROUP

Renames the group name for the current button. Only valid for buttons types that have groups i.e. Label buttons

Format: RENAME GROUP new_group_name

Arguments: new_group_name: a string containing the new button group name

Available: Available for code windows Version: 9 and later

Example:

RENAME GROUP “new group”
Changes the group name of the current button to “new group”


SEND

Changes the value of the button in the code input window with that button name

Format: SEND value TO BUTTON button_name OR SEND value TO BUTTON button_name IN WINDOW window_name

Arguments: value: a string or a number button_name: a string with the name of a button in the code input window window_name: the name of the code input window

Available: Available for spreadsheet windows Version: 9 and later

Example: 

SEND “new_string” TO BUTTON “name1”
Changes the displayed value of “name1” in the front code input window to “new_string”

SEND 37.4 TO BUTTON “name1”
Changes the displayed value of “name1” in the front code input window to 37.4

SEND “new_string” TO BUTTON “name1” IN WINDOW “codeWindow1”
Changes the displayed value of “name1” in the code input window “codeWindow1” to “new_string”


SEND BUTTON COLOR

Changes the background color of the button in the code input window with that button name

Format: SEND BUTTON COLOR ( red_color , green_color , blue_color ) TO BUTTON button_name OR SEND BUTTON COLOR ( red_color , green_color , blue_color , alpha_level ) TO BUTTON button_name OR SEND BUTTON COLOR ( red_color , green_color , blue_color ) TO BUTTON button_name IN WINDOW window_name OR SEND BUTTON COLOR ( red_color , green_color , blue_color , alpha_level ) TO BUTTON button_name IN WINDOW window_name

Arguments: color: a red, green or blue color value 0->100 alpha: color alpha with a value 0->100. 100 no transparency in the color button_name: a string with the name of a button in the code input window window_name: the name of the code input window

Available: Available for spreadsheet windows Version: 9 and later

Example:

SEND BUTTON COLOR (100,0,0) TO BUTTON “name1”
Changes the background color of “name1” in the front code input window to red

SEND BUTTON COLOR (100,0,0) TO BUTTON “name1” IN WINDOW “window1”
Changes the background color of “name1” in the code input window with title “window1” to red


SEND TEXT COLOR

Changes the text color of the button in the code input window with that button name

Format: SEND TEXT COLOR ( red_color , green_color , blue_color ) TO BUTTON button_name OR SEND TEXT COLOR ( red_color , green_color , blue_color , alpha_level ) TO BUTTON button_name OR SEND TEXT COLOR ( red_color , green_color , blue_color ) TO BUTTON button_name IN WINDOW “window1” OR SEND TEXT COLOR ( red_color , green_color , blue_color , alpha_level) TO BUTTON button_name IN WINDOW “window1”

Arguments: color: a red, green or blue color value 0->100 alpha: color alpha with a value 0->100. 100 no transparency in the color button_name: a string with the name of a button in the code input window window_name: the name of the code input window

Available: Available for spreadsheet windows Version: 9 and later. alpha_level available 9.3

Example:

SEND TEXT COLOR (100,0,0) TO BUTTON “name1”
Changes the text color of “name1” in the front code input window to red

SEND TEXT COLOR (100,0,0) TO BUTTON “name1” IN WINDOW “window1”
Changes the text color of “name1” in the code input window with title “window1” to red


TEXT COLOR

Changes the text color in the name of the button

Format: TEXT COLOR ( red_color , green_color , blue_color ) OR TEXT COLOR ( red_color , green_color , blue_color , alpha_level )

Arguments: color: a red, green or blue color value 0->100 alpha: color alpha with a value 0->100. 100 no transparency in the color

Available: Available for code windows Version: 9 and later. alpha_level available 9.3

Example:

TEXT COLOR (100,0,0)
Changes the text color to red