网格视图中的自定义类别 [英] custom catagry in grid view

查看:96
本文介绍了网格视图中的自定义类别的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我想按类别选择数据,就像我有3列数据
nam id距离和邮政编码我想选择0-10到11-20之间的距离,直到100或200,然后像这样输出
英里
+ 0-10城市
city1
ciry2
.... 3
.... 4
+ 11-20 city1
/....2
.... 3
''
.
.
.
.
91-100城市
+是折叠并展开


i want to select data as catagory wise like i have data with 3 column
nam id distance and zipcode i want to select that data whoes distance between 0-10 and then11-20 so on till 100 or 200 and make output like this
miles
+ 0-10 city
city1
ciry2
....3
....4
+ 11-20 city1
/....2
....3
''
.
.
.
.
91-100 city
+ is collapse and expand

推荐答案

.NET TreeView控件可帮助您构建预期的结果.这是示例代码:
.NET TreeView control helps you to build the expected result. Here is the sample code:
TreeNode node1 = new TreeNode("city1");
TreeNode node2 = new TreeNode("city2");
TreeNode node3 = new TreeNode("city3");
TreeNode[] array = new TreeNode[] {node1, node2, node3 };
treeNode = new TreeNode("0-10 city", array);
treeView1.Nodes.Add(treeNode);


这篇关于网格视图中的自定义类别的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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