C
Cirene
I'm setting a databound label's backcolor and forecolor like this...
<asp:Label ID="lblSampleColorScheme" runat="server"
BackColor='<%#
System.Drawing.Color.FromName(Eval("AttachmentEntityBackColor")) %>'
Font-Bold="True"
ForeColor='<%#
System.Drawing.Color.FromName(Eval("AttachmentEntityForeColor")) %>'
Text="CURRENT COLOR SCHEME"></asp:Label>
The problem is when the value is NULL. I get the above error. How can I
say, if it's null in the db then use "#ffffff"?
Thanks!
<asp:Label ID="lblSampleColorScheme" runat="server"
BackColor='<%#
System.Drawing.Color.FromName(Eval("AttachmentEntityBackColor")) %>'
Font-Bold="True"
ForeColor='<%#
System.Drawing.Color.FromName(Eval("AttachmentEntityForeColor")) %>'
Text="CURRENT COLOR SCHEME"></asp:Label>
The problem is when the value is NULL. I get the above error. How can I
say, if it's null in the db then use "#ffffff"?
Thanks!