<< Click to Display Table of Contents >> Grid function |
Grid function is a special function of Freestyle table component, which is used in the calculation of lattice;
Functions |
Syntax |
Instructions |
Examples |
---|---|---|---|
cell |
cell(string name)
or
cell(int row, int column) |
This expression calculates a value by subtracting dimensions from the component's level of detail *You can use row to indicate the current row number, column to indicate the current column number, rsize to indicate the total number of rows, and csize to indicate the total number of columns. |
For example: 1. Referenced by the name of the grid. For example: col('market')
For example: 2. Referenced by row and column coordinate values. For example: cell(1,3) represents the grid in the second row and fourth column. cell(row, 1), which represents the grid in the second column of the current row. If the current row is expanded, the expanded data will be obtained and calculated. cell(1, column) represents the cell in the second row of the current column. cell(row + 1, column-1), which means the cell on the left next to the current cell. cell(row, csize-1) represents the last cell in the current row. cell(rsize-1, column), which represents the last cell in the current column. cell(rsize-2, csize-2), which represents the cell in the second to last row and the second to last column.
*Note: Row and column are calculated from 0, and the first one in the upper left corner of the free list is the origin. rsize, csize are the specific number of rows and columns. Their value starts from 1.
|
rowTotal |
rowTotal(int column, int rstart, rend) |
Calculates the total number of rows.
*The parameter column indicates the column where the total of the calculation rows is located, rstart indicates the start row, and rend indicates the end row; |
For example: rowTotal(column-1, 0, rsize-1): The total value of the previous entire column. |
colTotal |
colTotal(int row, int cstart, cend) |
calculates the total of the columns.
*The parameter row indicates the row where the column total is calculated, cstart indicates the start column, and cend indicates the end column. |
For example: colTotal(row + 1, 2, 9): The total value of the data from the 3rd to 10th cells on the next row |
up |
up(int num) |
Functions that refer to cells in inter-cell calculations, represents the num cell above the current cell.
*num needs to be greater than 0. |
For example: up(1) Represents the first cell above the current cell. |
down |
down(int num) |
Functions that refer to cells in inter-cell calculations, represents the num cell below the current cell.
*num needs to be greater than 0. |
For example: down(1) Represents the first cell below the current cell. |
left |
left(int num) |
Functions that refer to cells in inter-cell calculations, represents the num cell to the left of the current cell.
*num needs to be greater than 0. |
For example: left(1) Represents the first cell to the left of the current cell. |
right |
right(int num) |
Functions that refer to cells in inter-cell calculations, represents the num cell to the right of the current cell.
*num needs to be greater than 0. |
For example: right(1) Represents the first cell to the right of the current cell. |