Need previous value after a DropDownList ListControl.SelectedIndexChanged Event

J

J055

Hi

I have a DropDownList with AutoPostBack = true. When this occurs I need to
load an ObjectDataSource control with the previous value. This is because
the DropDownList populates another list but should not load new data until a
Submit button is clicked.

I'd like to change the DropDownList value in the InputParameters collection
in the ObjectDataSource Selecting event.

e.g.

protected void ods_Selecting(object sender,
ObjectDataSourceSelectingEventArgs e)
{
// if DropDownList selected index changed then
e.InputParameters.Remove(key);
e.InputParameters.Insert(0, key, oldvalue);
}

what's the best/cleanest way to achieve this?

Thanks
Andrew
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,743
Messages
2,569,478
Members
44,899
Latest member
RodneyMcAu

Latest Threads

Top