Color

  • Thread starter Thread starter acko bogicevic
  • Start date Start date
A

acko bogicevic

Hi
In btnClick event i want to change back color of label

lbl.BackColor=Color.Red for example

but problem is than i have color like this #F9DA00
and lbl.BackColor = "#F9DA00" does not work.

Thanks Alex
 
Alex, use ColorTranslator like this:

Label1.BackColor = System.Drawing.ColorTranslator.FromHtml("#F9DA00");

hth

Jose
 
Back
Top