plz give soln
Here I've two datalists.and I want to enable one datalist by selecting an item in the drop down list( it is in user control).plz give me the solution.
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Suthish NairPosted Feb 16, 2011, 2:50 AM
Sam HobbsPosted Feb 14, 2011, 6:43 PM
Madhu KPosted Feb 14, 2011, 7:25 AM
If(DropDownList1.SelectedIndex==0)
{
// hide or enable the datalist controls according to requirement
DataList1.Visible=true;
DataList1.Enabled=true;
}else{DataList2.Visible=true; DataList2.Enabled=true;}
Amit ChoudharyPosted Feb 14, 2011, 6:53 AM
Write the code for enabling the second datalist in the selected_indexChanged event of first DataList.. and you'll be good to go..
Thanks..