Version
Report Server Version | Functional Change | Mobile Terminal Version |
---|---|---|
11.0 | - | Difference from V10.0: Such API is not provided in V10.0. |
11.0.7 | - | Added getPosition API, getRow API, getColumn API, getValue API, showToolTip API, and setStyle API in the FRM report. |
11.0.7 | - | Installed FineVis Data Visualization plugin of V1.8.0 and later versions, and allowed you to set getPosition API, getRow API, getColumn API, getValue API, showToolTip API, and setStyle API in FVS visualization dashboards. |
11.0.10 | 11.0.70 | Allowed you to set getPosition API, getRow API, getColumn API, getValue API, showToolTip API, and setStyle API in general reports. |
11.0.19 | - | Added setValue() API in the dashboard, and adapted the API to the FineVis Data Visualization plugin of V 1.17.0. |
Before API use, read JS API Compatibility Description carefully. APIs are supported in both general reports and FRM reports (new version) by default.
getPosition()
API | getPosition() | To obtain the current cell position, requiring you to get the cell object first. |
---|---|---|
Parameter | ||
Returned Value | Position:Array | The cell position, which is an array with indices starting from 0 (0 for the row, 1 for the column). |
Example | Example 1: You can obtain the positions of the cell row and cell column as well as the current cell position of the obtained cell defined as cell.
Example 2: In the FRM report, you can obtain the position information of cell A1 in the report block report0. _g().getWidgetByName('report0').getCell(1,1).getPosition(); Example 3: In a general report, you can obtain the position information of cell A1.
Example 4: In the FVS visualization dashboard, you can obtain the position information of cell A1 in the component Table1.
Example 5: In the FRM dashboard, you can set a pop-up prompt about the row and column information of cell A1 in the report block report0.
| |
Application Example | You can click the button to bring up the pop-up prompt in which the row and column information of cell A1 in report block report0 is displayed. For details, you can download the template Obtaining the Cell Object Position.frm FVS visualization dashboard: Obtaining the Cell Object Position.fvs | |
Mobile Terminal | This API is supported on mobile terminals. |
getRow()
API | getRow() | To obtain the cell object of the row where the current cell is located, and the returned row object can be set by the methods on row objects. |
---|---|---|
Parameter | - | - |
Returned Value | Object | Row cell object (JSON). When the cells are merged, the cell row object group will be returned. Assuming that cell A1 and cell A2 are merged, then the objects of the first row and the second row will be returned. |
Example | Example 1: If the obtained cell object is defined as cell, you can obtain the cell object of the row where the current cell is located.
Example 2: In the FRM dashboard, you can obtain the cell object of the row where cell A1 in the report block report0 is located.
Example 3: In a general report, you can obtain the cell object of the row where cell A1 is located.
Example 4: In the FVS visualization dashboard, you can obtain the cell object of the row where cell A1 in the component Table1 is located.
Example 5: In the FRM report, you can modify the text color to red and the font size to 14 for the content in the row where cell A1 is located in the report block report0.
| |
Application Example | In the FRM report, you can modify the text color to red and the font size to 14 for the content in the row where cell A1 is located in the report block report0. For details, you can download the template Modifying the Row Style.frm FVS visualization dashboard: Modifying the Row Style.fvs. | |
Mobile Terminal | This API is supported on mobile terminals. |
getColumn()
API | getColumn() | To get the cell object of the column where the current cell is located, and the returned column can be set by the methods on column objects. |
---|---|---|
Parameter | ||
Returned Value | Object | Column cell object (JSON) When the cells are merged, the cell column object group will be returned. Assuming that cell A1 and cell A2 are merged, then the objects of the first column and the second column will be returned. |
Example | Example 1: If the obtained cell object is defined as cell, you can obtain the cell object of the column where the current cell is located.
Example 2: In the FRM report, you can obtain the cell object of the column where cell A1 in the report block report0 is located.
Example 3: In a general report, you can obtain the cell object of the column where cell A1 is located.
Example 4: In the FVS visualization dashboard, you can obtain the cell object of the column where cell A1 in the component Table1 is located.
Example 5: In the FRM report, you can modify the text color to red and the font size to 14 for the content in the column where cell A1 is located in the report block report0.
| |
Application Example | In the FRM report, you can modify the text color to red and the font size to 14 for the content in the column where cell A1 is located in the report block report0. For details, you can download the template Modifying the Column Style.frm. FVS visualization dashboard: Modifying the Column Style.fvs. | |
Mobile Terminal | This API is supported on mobile terminals. |
getValue
API | getValue() | To obtain the type and the value of a cell. |
---|---|---|
Parameter | ||
Returned Value | string | Cell type and cell value |
Example | Example 1: If the obtained cell is defined as cell, you can obtain the type and the value of the current cell.
Example 2: In the FRM report, you can obtain the type and the value of cell A1 in the report block report0.
Example 3: In a general report, you can obtain the type and the value of cell A1.
Example 4: In the FVS visualization dashboard, you can obtain the type and the value of cell A1 in the component Table1.
Example 5: In the FRM report, you can set a pop-up prompt about printing the type and the value of cell A1 in the report block report0.
| |
Application Example | In the FRM report, you can set a pop-up prompt about printing the type and the value of cell A1 in the report block report0. For details, you can download the template Displaying the Cell Value by Clicking.frm. FVS visualization dashboard: Obtaining the Cell Value.fvs. | |
Mobile Terminal | This API is supported on mobile terminals. However, when getCell is used with getValue, such as
, the effect cannot be displayed in the data entry preview. |
setValue

API | setValue(value) | To set the value of a cell. |
---|---|---|
Parameter | value: any | Cell value in any format. |
Returned Value | void | |
Example | Example 1: In the FVS visualization dashboard, you can assign the value other regions to the component Table1 in cell A1.
Example 2: In the FRM report, you can assign the value other regions to cell A1 in the report block report0.
| |
Application Example | For details, you can download the template Modifying the Cell Value by Clicking.fvs. | |
Mobile Terminal | This API is not supported on mobile terminals. |
showToolTip
API | showToolTip(opts) | To add tooltips to a cell. |
---|---|---|
Parameter | opts: Object { show: boolean, content: { text: string, // text image: string, // image header: string // title } style: { } } ![]() | opts: pop-up option, which is an object. 1. show: whether to show a pop-up window, which is a boolean. true: to show the pop-up window. false: not to show the pop-up window. 2. content: You can select a field, or the cell value will be displayed. text: the prompt content, which is a string. image: URL path to the image, which is a string. The supported image formats include PNG and JPG. The image source can be a web page, as shown in the following figure. Alternatively, you can place the image in the report project directory %FR_HOME%\webapps\webroot and access it via URL, as shown in the following figure. header: the title. 3. style: You can select a field, or the default style will be displayed. For details about supported styles, see Style Attribute. |
Returned Value | - | - |
Example | Example 1: You can define the obtained cell as cell, set a prompt box whose title is Prompt and the content is Regional Sales Data in red.
Example 2: In the FRM report, you can set a prompt box whose title is Prompt and the content is Regional Sales Data in red for the report block report0.
Example 3: In a general report, you can set a prompt box whose title is Prompt and the content is Regional Sales Data in red for cell A1.
Example 4: In the FVS visualization dashboard, you can set a prompt box whose title is Prompt and the content is the cell value for cell A1 in the component Table1.
Example 5: In the FRM report, you can set a prompt box whose title is Prompt and the content is the cell value for the report block report0.
| |
Application Example | In the FRM report, you can set a prompt box whose title is Prompt and the content is the cell value for cell A1 in the report block report0. For details, you can download the template Text Tooltip in Cells with Hovering Cursor.frm. FVS visualization dashboard: Text Tooltip in Cells with Hovering Cursor.fvs. | |
Mobile Terminal | This API is not supported on mobile terminals. |
setStyle
API | setStyle(opts) | To set the cell style. |
---|---|---|
Parameter | opts: Object { fontFamily: String fontSize: number fontWeight: String color: String ........ } | opts: cell style attributes such as border and font color. For details about supported attributes, see Style Attribute. |
Returned Value | - | - |
Example | Example 1: You can set the font color to red and font size to 14 for the obtained cell named cell.
Example 2: In a general report, you can set the font color to red and font size to 14 for cell A1.
Example 4: In the FVS visualization dashboard, you can set the font color to red and font size to 20 for cell A1 in the component Table1.
Example 5: In the FRM report, you can set the font color to red and font size to 14 for cell A1 in the report block report0.
| |
Application Example | In the FRM report, you can set the font color to red and font size to 14, and make the font bold by clicking the button. For details, you can download the template Modifying Cell Style after Obtaining the Cell.frm. FVS visualization dashboard: Modifying Cell Style after Obtaining the Cell.fvs. | |
Mobile Terminal | This API is supported on mobile terminals. |
cellStr2ColumnRow
API | cellStr2ColumnRow(cell) | To obtain row and column indexes based on the cell number. |
---|---|---|
Parameter | cell | Cell number |
Returned Value | {col:colindex, row:rowindex} | Row and column indexes in JSON format col: column index, starting from 0 row: row index, starting from 0 |
Example | Example 1: In a general report or FRM report, you can obtain the row and column information of cell A1.
Example 2: In a general report or FRM report, you can use this API to print the row number of cell A1.
Example 3: In an FVS template, you can print the row and column number of a cell.
| |
Application Example | In the general report, you can click the button to print the row number of cell A1. In the FVS template, you can click the button to print the row and column numbers of cell A3. For details, you can download the template Printing the Row and Column Numbers of A Cell.fvs. | |
Mobile Terminal | This API is supported on mobile terminals. |
columnRow2CellStr
API | columnRow2CellStr({col:colindex, row: rowindex}) | To obtain the cell number based on the row and column number. |
---|---|---|
Parameter | {col:colindex, row:rowindex} | Row and column indexes in JSON format col: column index, starting from 0 row: row index, starting from 0 |
Returned Value | cell | Cell number |
Example | Example 1: In a general report or FRM report, you can obtain the cell number of the cell with row index 3 and column index 1.
Example 2: In a general report or FRM report, you can print the cell number of the cell with row index 3 and column index 1.
Example 3: In an FVS template, you can print the cell number of the cell with row index 3 and column index 1.
| |
Application Example | In the general report, you can print the cell number of the cell with row index 3 and column index 1. In the FVS template, you can print the cell number of the cell with row index 3 and column index 1. For details, you can download the template Obtaining the Cell Number Based on the Row and Column Number.fvs. | |
Mobile Terminal | This API in the general report or FRM report is not supported on mobile terminals. This API in the FVS template is supported on mobile terminals. |