将名称添加到数据绑定的下拉列表中 [英] Adding a name into a dropdownlist that is databound

查看:75
本文介绍了将名称添加到数据绑定的下拉列表中的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有没有办法可以将学校的名称添加到该学校的年度旁边的数据绑定下拉列表中?我的一个下拉列表中有学校数据库的名称。其他五年有这些年。具有年份的下拉列表也是数据绑定的。我想在适当的年份进入正确的学校,进入多年的下拉列表。我怎么能这样做?

Is there a way i can add the name of a school to a databound dropdownlist next to the year for that school? One of my dropdownlist has the name of schools databound to it. The other five has the years. The dropdownlist that have years are also databound. I am tring to get the right school with the right year into the years dropdownlist. How can I do this?

推荐答案

我认为如果你向你的数据源添加一个新列,在一列中包含名称和年份,它可以是一个很好的解决方案。之后,您可以将此列绑定到下拉列表,从而为所选学校选择合适的年份。
I think it can be a good solution if you add a new column to your datasource what contains in one column the name and the year. After that you can bound this column to the dropdownlist and thus you can choose the right year for your selected school.


这篇关于将名称添加到数据绑定的下拉列表中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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