会员
众包
新闻
博问
闪存
赞助商
HarmonyOS
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
DavidJGu's Blog
尼采说,宁可追求虚无也不能无所追求!
Keeping is harder than winning
博客园
::
首页
::
新随笔
::
联系
::
订阅
::
管理
公告
Simple operation algorithm of WebTree(2)
Posted on
2004-09-08 16:03
Let's DotNet
阅读(
463
) 评论(
0
)
收藏
举报
public
static
string
GetCheckedNodesofTree(Infragistics.WebUI.UltraWebNavigator.UltraWebTree objUltraTree)
{
string
strTagsSet
=
""
;
int
iCount
=
objUltraTree.Nodes.Count;
for
(
int
i
=
0
; i
<
iCount; i
++
)
{
strTagsSet
+=
GetCheckedNodes(objUltraTree.Nodes[i])
+
"
|
"
;
}
strTagsSet
=
strTagsSet.TrimEnd(
'
|
'
);
return
strTagsSet;
}
private
static
string
GetCheckedNodes(Infragistics.WebUI.UltraWebNavigator.Node objNode)
{
string
strTags
=
""
;
int
iCount
=
objNode.Nodes.Count;
if
(iCount
==
0
&&
objNode.Checked)
{
return
objNode.Tag.ToString().TrimEnd(
'
|
'
);
}
else
{
for
(
int
i
=
0
; i
<
iCount; i
++
)
{
string
strTemp
=
GetCheckedNodes(objNode.Nodes[i]);
strTags
+=
(strTemp.Trim()
==
""
?
""
:strTemp
+
"
|
"
);
}
return
strTags.TrimEnd(
'
|
'
);
}
}
刷新页面
返回顶部
博客园
© 2004-2025
浙公网安备 33010602011771号
浙ICP备2021040463号-3