UpdateCurrentValue - cCJGridColumn

Used to change the column value of the SelectedRow

Type: Procedure

Parameters: String sValue

sValueThe value to change

Procedure UpdateCurrentValue String sValue

Call: Send UpdateCurrentValue sValue


UpdateCurrentValue value is used to manually change the column value of the SelectedRow. It updates the datasource. With data-aware grids it will update the data dictionaries as needed.

Function EditRowPopup Returns Boolean
    Boolean bOk
    tTableDataLine DataLine
    Integer iSizeX2

    Get SelectedRowValue of oName to DataLine.sName
    Get SelectedRowValue of oType to DataLine.sType
    Get SelectedRowValue of oSize to DataLine.iSize
    Get SelectedRowValue of oDescription to DataLine.sDescription
    Get GetTableData of oDataPopup (&DataLine) to bOk                
    If bOk Begin
        Send UpdateCurrentValue of oName  DataLine.sName
        Send UpdateCurrentValue of oType  DataLine.sType
        Send UpdateCurrentValue of oSize  DataLine.iSize
        Send UpdateCurrentValue of oDescription DataLine.sDescription
        Send Request_Save
    Function_Return bOk

You can use SelectedRowValue to get the column value of the SelectedRow. You can use UpdateCurrentValue to change a SelectedRow's column value. You can use RowValue to get the column value of the any row.

If you need to change the value of a column in a non-selected row, you should interact directly with the datasource.

In order for UpdateCurrentValue to work, pbReadOnly must be set to False.