RadioButtonList

来源:百度知道 编辑:UC知道 时间:2024/05/15 00:43:34
我想给RadioButtonList的items项,绑定上图片,应该怎么做啊!谁能帮帮小弟啊?谢谢了!
先谢谢:zhaoyucai
不过我想要直接绑定图片啊,不和数据源联系,能行吗?您有没有什么好的方法啊?
再次谢谢

this.RadioButtonList1.DataSource = objDataSet; //你返回的数据源
this.RadioButtonList1.DataTextField = "字段名"; //你数据库中字段名
this.RadioButtonList1.DataValueField = "字段名"; //你数据库中字段名this.RadioButtonList1.DataBind(); //最后绑定一下

//其实应该和DropDownList下拉列表 的绑定是一样的