This is a migrated thread and some comments may be shown as answers.

BackColor change for Combobox, DateTimePicker, MaskedEditBox

1 Answer 71 Views
ComboBox and ListBox (obsolete as of Q2 2010)
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Victoria F
Top achievements
Rank 1
Victoria F asked on 05 Jan 2011, 05:15 PM
What I'm trying to do is depend on my search method I want to highlight some fields in my winform to make them required.
Some fields are RadComboBoxes, some of them are DateTimePickers, some MaskedEditBoxes.

On Click event of my search method I'm trying to set a BackColor for fields that are required to yellow.
radComboBox_1.BackColor = Color.Yellow;
EdMsk_A3.BackColor = Color.Yellow;
As soon as user fills out the required field it suppose to change color back to initial White background.

The problem is that the following code for the background change does not work.. BackColor of the combobox  never changed..
Thanks,
Victoria.

1 Answer, 1 is accepted

Sort by
0
Victoria F
Top achievements
Rank 1
answered on 05 Jan 2011, 06:01 PM
Sorry , never mind I found the answer :

radComboBox_1.ComboBoxElement.TextBoxElement.TextBoxItem.BackColor = Color.Yellow;
Tags
ComboBox and ListBox (obsolete as of Q2 2010)
Asked by
Victoria F
Top achievements
Rank 1
Answers by
Victoria F
Top achievements
Rank 1
Share this question
or