Sub B4XTable1_DataUpdated
For i = 0 To B4XTable1.VisibleRowIds.Size - 1
Dim RowId As Long = B4XTable1.VisibleRowIds.Get(i)
If RowId > 0 Then
'criteria
Dim Value As Int = B4XTable1.GetRow(RowId).Get("Estado")
If Value = 3 Then
SetRowColor(i, xui.Color_Green)
Continue
End If
End If
If i Mod 2 = 0 Then
SetRowColor(i, B4XTable1.EvenRowColor)
Else
SetRowColor(i, B4XTable1.OddRowColor)
End If
Next
End Sub
Sub SetRowColor (RowIndex As Int, Clr As Int)
For Each c As B4XTableColumn In B4XTable1.VisibleColumns
Dim pnl As B4XView = c.CellsLayouts.Get(RowIndex + 1) '+1 because of the header
pnl.Color = Clr
Next
End Sub