This method returns the data value of a specific field specified field in a specific specified row of a grid. The data does not have to be visible when this method is called. If In the event that the field name or row number does not exist, null is returned.
The data does not need to be visible (on screen) when calling this method.
|This method only works|
|when used where an RPG program is used to populate the grid in Rich Display Files. It does not work with|
|driven grids or with Genie generated grids|
|. In the case of database-driven and Genie generated grids, the getCellValue() API would instead be used.|
- row - the row number to retrieve the value from; when using events such as onrowclick, onrowdblclick, onrowmouseover, and onrowmouseout, the row variable is automatically passed into the event and can be used as the parameter to this method
- fieldName - the field name, as defined in the subfile record format
The following expression retrieves the customer id from the first row of the subfile:
- field value, if specified field is found on specified row.
- null, if specified field is not found on specified row.
var customerId = getObj("Grid1").grid.getDataValue(1, "CUSTID");