Posted on: 5/29/2014 5:51:40 PM | Views : 366

Hello guys,
I am using the approach to be able to iterate through the textboxes and dropdow list on a page

public static IEnumerable<Control> GetAllControls(Control parent) { if(null == parent) return null; return new Control[] { parent }.Union(parent.Controls.OfType<Control>().SelectMany(child => GetAllControls(child)); } foreach(DropDownList list in GetAllControls(this).OfType<DropDownList>()) { //TODO: add values to dictionary collections and append to session object } Now, after the loop and getting the values, I need to be able to store the droplist list ids and values into a sesion to be available elsewhere in the application.
Please help.

Thanks

Go to the complete details ...