<rad:RadMaskedTextBox ID="txtZip" Mask="#####-####" Width="60px" runat="server"
BackColor="#CCCCCC" Enabled="False">
</rad:RadMaskedTextBox>
<rad:RadNumericTextBox ID="txtLocationCode" MaxLength="2" Width="19px"
runat="server" BackColor="#CCCCCC" Enabled="False" Skin="Vista">
<NumberFormat AllowRounding="True"></NumberFormat>
</rad:RadNumericTextBox>
I want them to be disabled and grey background by default.
I have a checkbox on the form that when click I want to enable a group of controls and set their background back to white.
When I enable them I also set there background color to white.
However during mouseover the background goes back to the #CCCCCC color, Here is the javascript for the checkbox onclick event:
function
FormControls()
{
if (document.getElementById("ctl00_ContentPlaceHolder1_chkNewOffice").checked == true)
{
document.getElementById(
"ctl00_ContentPlaceHolder1_chkUseOnWebsite").disabled = false;
document.getElementById(
"ctl00_ContentPlaceHolder1_chkUseOnWebsite").parentElement.disabled=false;
document.getElementById(
"ctl00_ContentPlaceHolder1_txtLocationCode_text").disabled = false;
document.getElementById(
"ctl00_ContentPlaceHolder1_txtLocationCode_text").style.backgroundColor = '#FFFFFF';
}
else{
document.getElementById(
"ctl00_ContentPlaceHolder1_chkUseOnWebsite").disabled = true;
document.getElementById(
"ctl00_ContentPlaceHolder1_chkUseOnWebsite").parentElement.disabled = true;
document.getElementById(
"ctl00_ContentPlaceHolder1_txtLocationCode_text").disabled = true;
document.getElementById(
"ctl00_ContentPlaceHolder1_txtLocationCode_text").style.backgroundColor = '#CCCCCC';
}
}
What else do I need to enable to get rid of the #CCCCC background on mouseover?
Thank You,
Coty