Skip to content

SelectedRowValue - cCJGridColumn

Returns the column value for the SelectedRow

Type: Function
Return Data Type: String

Syntax

Function SelectedRowValue Returns String

Call Example

Get SelectedRowValue to StringVariable

Description

SelectedRowValue can be used to get the column value of the selected row. The message uses SelectedRowValueBeforeEdit.

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
    End
    Function_Return bOk
End_Function
Function CanEditColumn Integer iCol Returns Boolean
    String sValue
    Boolean bCanDo
    Integer iRow iSizeCol
    Handle hoDataSource
    Forward Get CanEditColumn iCol to bCanDo
    If (bCanDo) Begin
        Get piColumnId of oSize to iSizeCol
        If (iCol=iSizeCol) Begin
            Get SelectedRowValue of oType to sValue
            If (Uppercase(sValue)="DATETIME") Begin
                Move False to bCanDo
            End
        End
    End
    Function_Return bCanDo
End_Function

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

Return Value

The column value for the SelectedRow.