ref dropdownlist in itemdatabound event?

  • Thread starter Thread starter Tina
  • Start date Start date
T

Tina

In the ItemDataBound event I know how to reference the text in a text box in
a template column:
e.item.cells(0).text

but I can't figure out how to reference a dropdownlist in a template column:
e.item.cells(1).????????

how can I reference the control in the template column so that I can fill
it?
thanks,
T
 
Tina,
I think you have to look inside the cell to see if it has
a drop down list.

You may want to try using
e.Item.Cells[0].FindControl(controlID)

When you find it then you can cast it to an instance of a
DropDownList object and you can go about your business.

HTH,
Suresh.
 
Back
Top