If DataGridView1.Rows.Count <> 0 Then
            For i As Integer = 0 To DataGridView1.Rows.Count - 1
                If (i Mod 2) = 0 Then
                    DataGridView1.Rows(i).DefaultCellStyle.BackColor = System.Drawing.Color.LightGreen
                Else
                    DataGridView1.Rows(i).DefaultCellStyle.BackColor = System.Drawing.Color.LimeGreen
                End If
            Next
        End If


arrow
arrow
    全站熱搜

    Roger 發表在 痞客邦 留言(0) 人氣()