CS1033
error Expected the end of the statement.
#What it means
The statement was complete, but more text followed on the same line. Only scripts in the earlier syntax (saved before ChartScript moved to its current, brace-based syntax) can show it; the editor converts such a script to the current syntax when you open it, after which this cannot happen. In the current syntax the same mistake is CS1057.
#Typical cause
- Two statements on one line.
- A missing operator between two values, as in
close open. - A missing comma between arguments.
#How to fix it
Add the missing operator or comma, or put each statement on its own line (or separate them with ;).
#Example
In the earlier syntax
//@chartscript 1
indicator("Body size")
body = close open
plot(body)Fixed (the current syntax)
//@chartscript 1
indicator("Body size")
const body = close - open
plot(body)