生成Gridview [英] to generate Gridview
本文介绍了生成Gridview的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如何在运行时生成gridview,???我不想在我的设计页面中显示网格.
请帮助我...?
how to generate gridview at runtime,???i dont want to show the grid in my design page.
please help me...?
推荐答案
1.创建一个Gridview
2.创建一个数据集
3.将SQL查询的结果存储到数据集中
4.提供gridview的数据源作为数据集
5.用Gridviewcontrol绑定数据
步骤1:
Gridview myGv = new GridView();
步骤2-5在这里完成:
如何在网格视图中动态创建列 [
1. create a Gridview
2. create a dataset
3. store the results from SQL query into dataset
4. provide datasource of gridview as dataset
5. bind data with Gridviewcontrol
Step 1:
Gridview myGv = new GridView();
Step 2-5 is done here:
how to create columns dynamically in a grid view[^]
u可以通过juat创建
GridView gdv = new GridView();在后面的代码中,并且可以执行所需的操作.
u can juat create
GridView gdv = new GridView(); in code behind and can perform operations wat ever u want.
这篇关于生成Gridview的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文