M
Marc Miller
Hello,
I have a datagrid in which I change the color of the row, based on a value
in a particular column.
My problem is that I need to know the current row number in the data set
after I page from the
first page.
I see the error in my ways here, since I am constantly referring to rows 0
thru 4. What can I
use as a reference for introw in the rowcolor procedure?
Thanks,
Marc Miller
Dim i As Integer
For i = 0 To Me.dgPODetails.PageSize - 1 ' Page size here is 5
Me.rowcolor(i)
Next i
---------------------------------------------------------------------
Private Sub rowcolor(ByVal intRow As Integer)
Dim IsClosed As String
IsClosed = objDs.Tables(0).Rows(intRow).Item("closed_code")
If IsClosed = "CLOSED" Then
Me.dgPODetails.Items(intRow).ForeColor = Color.FromName("Red")
etc, etc................................
END SUB
I have a datagrid in which I change the color of the row, based on a value
in a particular column.
My problem is that I need to know the current row number in the data set
after I page from the
first page.
I see the error in my ways here, since I am constantly referring to rows 0
thru 4. What can I
use as a reference for introw in the rowcolor procedure?
Thanks,
Marc Miller
Dim i As Integer
For i = 0 To Me.dgPODetails.PageSize - 1 ' Page size here is 5
Me.rowcolor(i)
Next i
---------------------------------------------------------------------
Private Sub rowcolor(ByVal intRow As Integer)
Dim IsClosed As String
IsClosed = objDs.Tables(0).Rows(intRow).Item("closed_code")
If IsClosed = "CLOSED" Then
Me.dgPODetails.Items(intRow).ForeColor = Color.FromName("Red")
etc, etc................................
END SUB