ForeColor of validationSummary control

  • Thread starter Thread starter Sam
  • Start date Start date
S

Sam

Hi guys,

Is it possible to update this property programatically? would someone please
give me a hand? The message I got back when I run one of my web pages is:
Parser error "<%errorColor%>" is not a valid value for int32.

Here is what I have:

Public headerColor as string = "00FFFF"
Public errorColor as String = "FFCC00"

<TD vAlign ="top" bgColor="<%=headerColor%>">

<asp:ValidationSummary id="ValidationSummary1" runat="server"
ForeColor="<%errorColor%>" Width="646px">


Also the headerColor and errorColor are programatically set by my program.
Thank you



Regards,

Sa,
 
Could you put something like this in the page_load event?
ValidationSummary1.BackColor = ColorTranslator.FromHtml(errorColor)
 
David,

It works, this is what I'm looking for. Thanks so lots

Regards,

Sam
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top