<asp:TemplateColumn HeaderText="选定<br>厂家">
<ItemTemplate>
<asp:Label id=Label_zbcj runat="server" Text='<%# DataBinder.Eval(Container, "DataItem.xdcj") %>'>
</asp:Label>
</ItemTemplate>
<FooterTemplate>
<FONT face="宋体"></FONT>
</FooterTemplate>
<EditItemTemplate>
<FONT face="宋体">
<asp:DropDownList id="DropDownList_zbcj" runat="server" >
<asp:ListItem Value="A">A</asp:ListItem>
<asp:ListItem Value="B">B</asp:ListItem>
<asp:ListItem Value="C">C</asp:ListItem>
<asp:ListItem Value="D">D</asp:ListItem>
<asp:ListItem Value="E">E</asp:ListItem>
</asp:DropDownList></FONT>
</EditItemTemplate>
</asp:TemplateColumn>如果选择“B”,编辑的时候下拉列表中显示“B”而不是显示第一个“A”
<ItemTemplate>
<asp:Label id=Label_zbcj runat="server" Text='<%# DataBinder.Eval(Container, "DataItem.xdcj") %>'>
</asp:Label>
</ItemTemplate>
<FooterTemplate>
<FONT face="宋体"></FONT>
</FooterTemplate>
<EditItemTemplate>
<FONT face="宋体">
<asp:DropDownList id="DropDownList_zbcj" runat="server" >
<asp:ListItem Value="A">A</asp:ListItem>
<asp:ListItem Value="B">B</asp:ListItem>
<asp:ListItem Value="C">C</asp:ListItem>
<asp:ListItem Value="D">D</asp:ListItem>
<asp:ListItem Value="E">E</asp:ListItem>
</asp:DropDownList></FONT>
</EditItemTemplate>
</asp:TemplateColumn>如果选择“B”,编辑的时候下拉列表中显示“B”而不是显示第一个“A”
解决方案 »
- 高手请进,在线急等【。。。。。。。。。。。】
- 关于添加栏目后自动显示在首页的问题.
- 我用表格定,如何可以让按钮在一格子居中?为什么鼠标拖动定位不行?
- 问一个html的简单问题
- 帮忙看下哪有语法错误~
- 考勤管理系统的问题
- 托管与非托管资源怎么区分?
- 运行时DataGrid中某列标题不能正常显示,求救!!
- 如何获取背景颜色值
- 各位兄弟知不知道哪里有WINDOWS XP 安装程序下载呀!试用版也行。
- ado.net的问题
- |zyciis| 如何实现用户登录后就跳转出原来的页面 我用Request.UrlReferrer.AbsolutePath的话,但当是用location.href='XXX' 方法时为null
If e.Item.ItemType = ListItemType.EditItem Then
Dim DropDownList_zbcj As DropDownList
DropDownList_zbcj = e.Item.FindControl("DropDownList_zbcj")
DropDownList_zbcj.Items.FindByText(e.Item.Cells(23).Text.Trim()).Selected = True
End If
End Sub