Scripts can be divided in three groups by designation.

Event Handlers

Event handler is a script representing sequence of operators executed when the event appears. All scripts of this type can be found in the Script group property via the Property Grid.

 Property   Objects    Description  
 GenerateScript   All objects   Code executed before the object is generated 
 ManualBuildScript   Page   Code executing generation of the page content. If the script is set, standard rendering mechanism is unavailable 
 CommonScript   Document   Code of the main part of expressions. Here you can declare global variables, functions, procedures 
 GetDataScript   DataBand, CrossBand   Code of the expression that will be executed when the data is got from the data source 

Property Binding

Property binding is a script representing expression connected to the object property; its calculation result is set as a value for this property. Expressions can be set for the most object properties in the Property Grid on the Bindings tab. Expressions are calculated before the object rendering before the GenerateScript is called. The order of expressions calculation is not defined, that is why we don’t recommend writing expressions which logic is based on the order of expressions calculation for different properties.

For example,

textBox.Value = a + b
textBox.Style = (textBox.Value == 0) ? "Zero" : "Normal"

There are no errors, but expression calculation result for the textBox.Style property can be invalid. It is necessary to set property

textBox.Style = (a + b == 0) ? "Zero" : "Normal"


Properties-Expressions are special properties getting value of the certain type. Properties-bindings are analogous to the property bindings, but they don’t match any property. Result got by the expression is used but it is not stored in the property.

Properties-expressions are set in the Property Grid; you can use Script Editor to set them. There are properties representing collection of properties-expressions.


Calculation result sets order of grouping. Expression gets group key (if the key is equal, rows are in the same group). Calculated value is not set for the property but they are used in inner rendering algorithms.
(More information about grouping)

Calculation result sets order of sorting.
(More information about sorting grouped lists)

Calculation result sets rule of filtering data.
(More information about filtering lists)

Collection of sorting conditions. Each sorting condition is an object with the Expression property that sets expression getting key by which the data is sorted.
(More information about lists sorting)

Collection of aggregation functions expressions.
(More information about totals)

As these expressions are calculated for the inner logic of rendering time of calling and order of calculation is not set. You shouldn’t create logic based on assumption about order or time of calculation. As a rule, such expressions are based on the source data value. Of course, it is possible to assume that scripts connected to initialization of the whole document and DocumentScripts script class will be executed at first.

Add Feedback