Console#
Introduction#
The VEXcode Console is displayed in the Monitor window within VEXcode. Console blocks can display text, numbers, and variable values while a project is running.
Below is a list of all available blocks:
print on console — Displays text, numbers, or variable values in the Console.
set cursor to next row on console — Moves the cursor to the next row in the Console.
clear all rows on console — Clears all rows in the Console.
set print precision on console — Sets how many decimal places are displayed when printing numbers.
print on console#
The print on console stack block displays text, numbers, or variable values in the Console at the current row.
If the block is not expanded to include and set cursor to next row, the next printed value will appear immediately after the previous value on the same row.
print [VEXcode] on console ▶
Parameters |
Description |
|---|---|
value |
The text, number, or variable value to display in the Console. |
expanding arrow |
Expands the block to include and set cursor to next row, which moves the cursor to the next row after the value is printed. If this option is not used, the next printed value appears immediately after the previous value on the same row. |
Example
when started
[Display a message in the Console.]
print [Hello, CTE!] on console ▶

set cursor to next row on console#
The set cursor to next row on console stack block moves the cursor to column 1 on the next row in the Console. The next value printed will appear on that row.
Use this block when you want the next printed value to start on a new row. If this block is not used, and the previous print on console block was not expanded to include and set cursor to next row, the next printed value will appear immediately after the previous value on the same row.
set cursor to next row on console
Parameters |
Description |
|---|---|
This block has no parameters. |
Example
when started
[Display two lines of text.]
print [Row 1] on console ▶
set cursor to next row on console
print [Row 2] on console ▶

clear all rows on console#
The clear all rows on console stack block clears all rows from the Console and moves the cursor back to the first row.
clear all rows on console
Parameters |
Description |
|---|---|
This block has no parameters. |
Example
when started
[Clear the Console after printing.]
print [This will disappear...] on console ▶
wait [2] seconds
clear all rows on console
set print precision on console#
The set print precision on console stack block sets how many decimal places are displayed when numbers are printed in the Console. This setting applies to numbers printed after this block is used. At the start of a project, print precision is set to 1, so numbers print with no decimal places.
set print precision to [0.1 v] on console
Parameters |
Description |
|---|---|
precision |
The print precision to use:
|
Example
when started
[Print 1/3 as 0.33.]
set print precision to [0.01 v] on console
print ([1] [math_division v] [3]) on console ▶
