I have got problem with check-box to enable corresponding control next to it. My Requirement is at the page load we want to disable the all textboxes and dropdownlists by using checkbox if the check-box is checked the control next to that check-box will be enabled for that i have done like this....
at page load
i have written like this
protected void Page_Load(object sender, EventArgs e)
ChckOrdType.Checked = false;
ChkPlntPric.Checked = false;
ChkExcluBro.Checked = false;
and then in checkbox check changed event i have written like this
protected void ChckOrdType_CheckChanged(object sender, EventArgs e)
ddlOrdType.Enabled = true;
ddlOrdType.Enabled = false;
protected void chkPlntPric_CheckChanged(object sender, EventArgs e)
ddlPlntPric.Enabled = true;
ddlPlntPric.Enabled = false;
protected void chkExcluBro_CheckChanged(object sender, EventArgs e)
ddlExcluBroker.Enabled = true;
ddlExcluBroker.Enabled = false;
but results is like this ... I am getting checkbox not checked and control next to it is enabled...But this not what i want
My results is if the check-box is not checked the control next to it is disabled would any one pls help on this...
Thanks In advance......