[英]Color coding cells in datagridview based on cell value
嘗試這個:
For each row As DataGridViewRow In Datagridview1
If row.Cells(3).Text.Trim = "High" Then
row.Cells(3).Style.Backcolor = Color.Red
Else If row.Cells(3).Text.Trim = "Low" Then
...
Else If row.Cells(3).Text.Trim = "Medium" Then
...
End If
Next
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.