Background color when control is disabled

J

James Ramaley

Setting the ReadOnly property of my controls changes the background
color. The same happens when I set Enabled = False. Where does .NET
get the new background color from? Is it configurable?

thanks
 
C

Cor Ligthert

James,

Strange, never saw this, do you have a piece of your code where that is in?

Cor

"James Ramaley"
...
 
K

Ken Tucker [MVP]

Hi,

No you cant change the background color of a control like a
textbox that is readonly. You would have to make your own textbox to change
the background color. The systemcolors class contains many of the standard
colors of a control.

Ken
------------------------
Setting the ReadOnly property of my controls changes the background
color. The same happens when I set Enabled = False. Where does .NET
get the new background color from? Is it configurable?

thanks
 

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

Top