The following CS0103 error code information is provided within the context of NinjaScript. The examples provided are only a subset of potential problems that this error code may reflect. In any case, the examples below provide a reference of coding flaw possibilities.
When a variable is used before declaration, the compiler will not know what it is. This error is also commonly invoked by typos.
Please ensure that you have declared your variables prior to using them. If variables are declared or properties already exist, please check for typos.
// Erroneous Sample Code - 'CurentBar' does not exist since it has been spelled incorrectly (missing an 'r')
if (CurentBar < 10)
// Resolution Sample Code - 'CurrentBar' exists since it is spelled correctly
if (CurrentBar < 10)
// Erroneous Sample Code - 'newVariable' is not declared
newVariable = 10;
// Resolution Sample Code - 'newVariable' is now declared as an integer
int newVariable = 10;