如何使用templatefield在Gridview中添加下拉列表 [英] How to add a dropdown list in Gridview with templatefield

查看:169
本文介绍了如何使用templatefield在Gridview中添加下拉列表的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想用asp gridview绑定下拉列表,但gridview不应该从数据库表绑定。我只是将网格的模板字段插入到新表中。请帮助我..提前感谢

解决方案

您可以查看此链接作为参考....



http://www.aspsnippets.com/文章/如何填充-DownDownList-in-GridView-in-ASPNet.aspx [ ^ ]



http://msdn.microsoft.com/en-us/library/vstudio/ms178294(v= vs.100).aspx [ ^ ]



http://www.c-sharpcorner.com/Blogs/14031/fill-dropdown-list-on-gridvie w-in-Asp-Net.aspx [ ^ ]


Quote:

当我用虚拟数据集绑定网格时,它工作得很好但是现在我想在第一行中插入数据时在网格中添加一个新行

这就是你需要的 - 动态添加和删除ASP.NET GridView中的行 [ ^ ]


i want to bind a dropdown list with asp gridview, but the gridview should not bind from a database table. I just only insert the template field of grid into a new table. kindly help me please.. thanks in advance

解决方案

You can check this link as your reference....

http://www.aspsnippets.com/Articles/How-to-populate-DropDownList-in-GridView-in-ASPNet.aspx[^]

http://msdn.microsoft.com/en-us/library/vstudio/ms178294(v=vs.100).aspx[^]

http://www.c-sharpcorner.com/Blogs/14031/fill-dropdown-list-on-gridview-in-Asp-Net.aspx[^]


Quote:

When i bind the grid with a dummy data set, it works perfectly but now i want to add a new row in a grid when i insert data in first row

This is what you need - Dynamically adding and deleting rows from ASP.NET GridView[^].


这篇关于如何使用templatefield在Gridview中添加下拉列表的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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