Quantcast
Channel: SharePoint 2010 - Development and Programming forum
Viewing all articles
Browse latest Browse all 11571

GridView ItemTemplate operation

$
0
0

Hi, I have a gridview that I have to edit the background color according to 4 different results (> 0, > 1 < 30, > 31 < 90, > 91 < 300), at the moment I can evaluate only 2 results (< 0):

<asp:Label ID="Label1" runat="server" Text='<%# Bind("Retard") %>' CssClass="a" BackColor='<%#(Convert.ToInt32(Eval("Retard")) < 0) ? System.Drawing.ColorTranslator.FromHtml("#FF8888") : System.Drawing.ColorTranslator.FromHtml("#FFFF77")%>'></asp:Label>

Any help please? thanks




Viewing all articles
Browse latest Browse all 11571

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>