help me with this... urgent... code below...
-
It should be from blue to red gradient color... the backcolors of these rows return green gradient... please help me revise the code... thanks... Protected Sub GridView1_DataBound(ByVal sender As Object, ByVal e As System.EventArgs) Handles GridView1.DataBound Dim red As Integer = &HFF0000 Dim blue As Integer = &HFF Dim green As Integer = &HFF00 Dim noRows As Integer Dim incDiff As Integer Dim currentColor As Integer noRows = GridView1.Rows.Count incDiff = (red / green) / noRows currentColor = green For x As Integer = 0 To noRows - 1 GridView1.Rows(x).BackColor = Color.FromArgb(currentColor) currentColor += incDiff Next End Sub
-
It should be from blue to red gradient color... the backcolors of these rows return green gradient... please help me revise the code... thanks... Protected Sub GridView1_DataBound(ByVal sender As Object, ByVal e As System.EventArgs) Handles GridView1.DataBound Dim red As Integer = &HFF0000 Dim blue As Integer = &HFF Dim green As Integer = &HFF00 Dim noRows As Integer Dim incDiff As Integer Dim currentColor As Integer noRows = GridView1.Rows.Count incDiff = (red / green) / noRows currentColor = green For x As Integer = 0 To noRows - 1 GridView1.Rows(x).BackColor = Color.FromArgb(currentColor) currentColor += incDiff Next End Sub
im' not really that good with VB.net but i dont see anything mentioning the color blue in that code. Maybe someone else knows what it is, but im not sure if that's it. -Think not of the problem But of the solution! -Mind what people do, not what they say, for deeds will betray an lie. -The only sovereign you can allow to rule you is reason. -Contradictions don't exist, in whole or in part.
-
It should be from blue to red gradient color... the backcolors of these rows return green gradient... please help me revise the code... thanks... Protected Sub GridView1_DataBound(ByVal sender As Object, ByVal e As System.EventArgs) Handles GridView1.DataBound Dim red As Integer = &HFF0000 Dim blue As Integer = &HFF Dim green As Integer = &HFF00 Dim noRows As Integer Dim incDiff As Integer Dim currentColor As Integer noRows = GridView1.Rows.Count incDiff = (red / green) / noRows currentColor = green For x As Integer = 0 To noRows - 1 GridView1.Rows(x).BackColor = Color.FromArgb(currentColor) currentColor += incDiff Next End Sub