M
MRW
I have a GridView which displays simple labels in ItemTemplate, and
when it goes to EditTemplate, one field is a dropdown list and the
other is a text box.
On gvTT_RowUpdating(..), I'm able to access the text box without any
issue, using:
Dim newDate As TextBox = gvTT.Rows(gvTT.EditIndex).FindControl("Date")
However, for the dropdown, when I use:
Dim ddlCategories As DropDownList =
gvTT.Rows(e.RowIndex).FindControl("ddlCategories")
I can access all the properties of the dropdown (being it's finding
it), however, I cannot access the selected value!
Response.Write(ddlCategories.SelectedIndex)
Does anybody know why I cannot access the dropdown list, yet I can
access the text boxes???
Thanks for ANY help!
when it goes to EditTemplate, one field is a dropdown list and the
other is a text box.
On gvTT_RowUpdating(..), I'm able to access the text box without any
issue, using:
Dim newDate As TextBox = gvTT.Rows(gvTT.EditIndex).FindControl("Date")
However, for the dropdown, when I use:
Dim ddlCategories As DropDownList =
gvTT.Rows(e.RowIndex).FindControl("ddlCategories")
I can access all the properties of the dropdown (being it's finding
it), however, I cannot access the selected value!
Response.Write(ddlCategories.SelectedIndex)
Does anybody know why I cannot access the dropdown list, yet I can
access the text boxes???
Thanks for ANY help!