hi experts,
i have a problem calling an event handler from another control
scenario:
1-i have two drop down lists the main dropdown list :
when the selected index changed event is called, another drop down list appears with a certain value according to the selected value of the main....
2-the second drop down list selected index changed event executes some functions on a check boxes list
the problem :
when the value of the second dropdown list is assigned i need to call the selected index changed event of the second drop down list to execute the functions on the check boxes list
any ideas ????
Loading


Dorababu MekaRank #457 · 5.5K reputationPosted Sep 13, 2011, 7:03 AM EDT
yourdropdown_SelectedIndexChanged(this,Eventargs.Empty)
Dorababu MekaRank #457 · 5.5K reputationPosted Sep 13, 2011, 6:47 AM EDT
Morcos Adel115 reputationPosted Sep 13, 2011, 7:00 AM EDT
Dorababu MekaRank #457 · 5.5K reputationPosted Sep 13, 2011, 7:55 AM EDT
Morcos Adel115 reputationPosted Sep 14, 2011, 1:52 AM EDT
Dorababu MekaRank #457 · 5.5K reputationPosted Sep 14, 2011, 1:54 AM EDT
VulpesRank #55 · 29.2K reputationPosted Sep 14, 2011, 2:15 AM EDT
Dorababu MekaRank #457 · 5.5K reputationPosted Sep 14, 2011, 3:43 AM EDT
yourdropdown_SelectedIndexChanged(yourdropdownname,Eventargs.Empty)
be sure that you are raising for that particular event and also check whether SelectedIndexChanges exists for that dropdown then only it works
Prabhu RajaRank #861 · 2.6K reputationPosted Sep 14, 2011, 4:46 AM EDT
Call SelectionIndex_Changed Event Handler inside of SelectChange_Commited Event Handler of Second Drop-down list.
----------------------------------------
If this helps you, then mark as "Correct Answer"
Thank You
Morcos Adel115 reputationPosted Sep 21, 2011, 12:53 AM EDT
but the problem still not solved as when i call the selected index changed as follow
protected void TypesDropDown_SelectedIndexChanged(object sender, EventArgs e)
{
GetAllReasons(DropDown.SelectedItem.Value)
}
When the Event occurs the DropDown.SelectedItem.Value is null
any ideas ?????
VulpesRank #55 · 29.2K reputationPosted Sep 21, 2011, 1:01 AM EDT
Morcos Adel115 reputationPosted Sep 21, 2011, 1:10 AM EDT
Morcos Adel115 reputationPosted Sep 21, 2011, 1:14 AM EDT
as when the control visibility set to false the values is not set but when the visibility is set to true the values are assigned well.....
VulpesRank #55 · 29.2K reputationPosted Sep 21, 2011, 1:55 AM EDT
As it won't be rendered when the Visible property is false, that's entirely plausible.