Declaration and Assignment
JavaScript is a weakly-typed language. This means variables are not assigned a type. A variable can be assigned any value. “The type of the variable is determined by the value currently assigned to it. Consequently, a local variable does not need to be declared before it is used.
var variable_name= "Hello"; // -- recommended
message1= "Hello"; // -- will also work
var count = 100;
If a variable is used as a report level variable, it must be declared using the 'var' keyword.
// put this in onLoad handler
var pageTotal = 0;
After the variable is declared, it can be used everywhere as a shared report instance variable.
| << Comments and Names | © 1996-2013 InetSoft Technology Corporation (v11.5) | Object Types and Scopes >> |