不同的case不同的底色

  '_row.DefaultCellStyle.BackColor = color_inCase     '  底色改为 淡红
            '  上面以前,所有的case都是一种底色
            '  下面现在,不同的case不同的底色(取决于其 case ID)
            Dim idR As Integer = CInt(_caseID.Substring(3, 7)) * 25
            Dim idG As Integer = CInt(_caseID.Substring(8, 2)) * 100 + CInt(_caseID.Substring(6, 4))
            Dim idB As Integer = CInt(_caseID.Substring(7, 3)) * 10
            idR = 255
            idG = idG Mod 255
            idB = idB Mod 255
            Dim _color As Color = Color.FromArgb(idR, idG, idB)
            _row.DefaultCellStyle.BackColor = _color     '  底色改为 这种颜色
posted @ 2020-01-10 11:41  gaoleionline  阅读(142)  评论(0)    收藏  举报