前几天写了个ASP.NET程序,用到了treeview作为左边菜单,依据用户的角色来初始treeview,比较简单实用,所以现在总结一下,和博友们共享一下。
  首先需要一个关系数据库表结构:就这个结构


NodeId ModualID NodeName NodeURL
1 <null> head1 URL
2 <null> head2 URL
3 <null> head3 URL
4 1 head11 URL
5 2 head21 URL
6 3 head31 URL

treeview 和数据源绑定public void inimenu(string strrole)

run ------>
treeview 和数据源绑定
可以了,呵呵

相关文章:

  • 2021-04-21
  • 2021-05-17
  • 2021-11-06
  • 2021-09-28
  • 2021-11-20
  • 2022-01-12
  • 2021-10-21
  • 2022-01-08
猜你喜欢
  • 2021-12-05
  • 2021-12-07
  • 2021-06-02
  • 2021-12-04
  • 2021-06-05
  • 2021-10-27
  • 2021-03-28
  • 2021-04-10
相关资源
相似解决方案