日期:2014-05-17 浏览次数:20388 次
<Columns>
<asp:BoundColumn DataField="Id">
</asp:BoundColumn>
<asp:TemplateColumn HeaderText="类型">
<ItemTemplate>
<%# DataBinder.Eval(Container.DataItem, "TypeName").ToString()%>
</ItemTemplate>
<EditItemTemplate>
<asp:DropDownList runat="server" ID="Dropdownlist2" AutoPostBack="true" OnSelectedIndexChanged="Dropdownlist2_SelectedIndexChanged" ></asp:DropDownList>
</EditItemTemplate>
</asp:TemplateColumn>
<asp:BoundColumn DataField="ABC">
</asp:BoundColumn>
<asp:EditCommandColumn CancelText="取消" EditText="编辑" UpdateText="更新"></asp:EditCommandColumn>
</Columns>
protected void Dropdownlist2_SelectedIndexChanged(object sender, EventArgs e)
{
DropDownList ddl = (DropDownList)sender;
TextBox strABC=????(我想找到DataField="ABC"这一列的TextBox)
}