I get error ‘Value of String cannot be converted System.Drawing.Color’ when I use label1.BackColor= ‘Red’

Platform: ASP.NET| Category: GDI+

Try
VB.NET


Label1.BackColor = System.Drawing.Color.FromName('Green')

C#


Label1.BackColor = System.Drawing.Color.FromName('Green');

Share with

Related FAQs

Couldn't find the FAQs you're looking for?

Please submit your question and answer.