下拉列表ASP .NET问题:两个下拉列表 - 两者都是数据限制和选择用户名 [英] Dropdown list ASP .NET Issue: Two Dropdown list- both are data bounded and on Selecting the User name

查看:62
本文介绍了下拉列表ASP .NET问题:两个下拉列表 - 两者都是数据限制和选择用户名的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

下拉列表ASP .NET问题:两个下拉列表 - 都是数据限制和选择用户名,日期下拉是自动填充,如果只有1个日期我无法选择相同。根据所选日期,显示数据网格,只有1个值日期我无法选择它,以便显示数据网格。请帮帮我。

Dropdown list ASP .NET Issue: Two Dropdown list- both are data bounded and on Selecting the User name, Date Drop down is auto populated, If there is only 1 date i am not able to select the same. As based on selected date , Data Grid is displayed, only 1 value dates i am unable to select it so that data grid is displayed. Please help me out.

推荐答案

根据我的理解问题,您在下拉列表中选择名称,并根据第二个下拉列表中的日期填写。现在填充gridview,在填充日期下拉列表的同时绑定gridview。



同时使日期下拉列表 AutoPostBack =true并在 SelectedIndexChanged 日期事件下拉列表中再次绑定gridview,这样如果您获得多个日期并更改选择,您的网格也将相应地填充。



问候..:)
As per as i understand the question,you are selecting names in dropdown and based on that dates are being filled in second dropdown.Now to populate gridview,bind gridview at the same time dates dropdown is being filled.

Also make dates dropdown AutoPostBack="true" and bind gridview again on SelectedIndexChanged event of dates dropdown,so that if you get more then one dates and you change the selection,your grid will also be populated accordingly.

Regards..:)


这篇关于下拉列表ASP .NET问题:两个下拉列表 - 两者都是数据限制和选择用户名的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆