What is the proper way to fire an ASP.NET control event programatically? I am looking to refactor a little code and I see items sprinkled in the code behind coded like this; the developer is calling the event handler and saturating it with params. for a DropDownList
ddlAddress.SelectedIndex = 1;
ddlAddress_SelectedIndexChanged(null, new EventArgs());
& for a RadioButtonList
rblAction.SelectedIndex = 0;
rblActionType_SelectedIndexChanged(null, new EventArgs());
Is this normal coding practice? What should I do as to not disrupt/break the page? Any thoughts or suggestions would be appreciated.
Thanks, ~ck in San Diego