Tuto WINDEV Mobile 25

84 Part 4: Programming concepts Summary scope diagram Each level accesses the variables of higher levels. Project UI (Windows, Pages, Mobile windows, Reports) Processes Global variables Global procedures Local variables Global variables Local procedures A variable is global when it is declared: • in the initialization code of project (or in the declaration code of set of procedures). The variable is global to the project. • In the declaration code of global variables of window, page or report. The variable is global to the element (window, page or report) where it was declared. In all other cases, a variable is local to the process where it is declared. Simple operations on the variables Several mathematical operators can be used to perform calculations on variables: • + to perform an addition. • - to perform a subtraction. • * to perform a multiplication. • / to perform a division. Other operators can be used to perform calculations: • ++ to increment from 1 (add 1 to the variable). • - - to decrement from 1 (subtract 1 from the variable). • += to assign by adding a value. • += to assign by subtracting a value.

RkJQdWJsaXNoZXIy NDQ0OA==