DataList - Capture the SelectedIndexChanged of a dropdownlist within template

  • Thread starter Thread starter Todd Fisher
  • Start date Start date
T

Todd Fisher

I need help please...
I am try to capture the selectedindexchanged on a dropdownlist in a
datalist template.

I want to update another dropdown in the template based off of my
first dropdown choice selection.

I assume you would set the selectedindex change of the dropdown field
on the itemdatabound of the template but... I haven't figured it out
yet.

Any help is appreciated.
Thank you.
 
Never tried doing something like this but will help you brainstorm a bit

try autopostback=true for the DDL
now on SelectIndexChanged event handler
try and get the value
next try and get hold of the parent ie the datagrid item the DDL belongs to
once you have that
grab hold of the required DDL (the second one) using item.FindControl
and try and set its selected index to whatever you fancy

you reckon that would work ?

HTH

HD
 
Back
Top