This is how it goes..
Add Attributes to the checkbox in item data bound
For Each dgi In dgCol.Items
Dim chk As CheckBox = CType(dgi.FindControl("chkSelect"), CheckBox)
chk.Attributes.Add("onclick", "javascript:Temp('" & CType(dgi.FindControl("ddMapToColumn"), DropDownList).ClientID & "');")
Next
The Java script that does the Enabling / Disabling is as follows..
function Temp(drpdown)
{
document.getElementById(drpdown).disabled = !document.getElementById(drpdown).disabled;
}
Nothing much is required apart from this and the job is done !!
Thursday, March 20, 2008
Subscribe to:
Post Comments (Atom)

0 comments:
Post a Comment