.net2005如何获取treeview 当前节点的引用??
原来2003我的代码是:
string str = this.Request.Params[ "__EVENTARGUMENT "].ToString();
if (str != " ")
{
if (str.Length == 12)
{
for (int i = 0; i < TreeView1.Nodes.Count; i++)
{
for (int j = 0; j < TreeView1.Nodes[i].ChildNodes.Count; j++)
{
if (str == TreeView1.Nodes[i].ChildNodes[j].NodeData)
{
TreeView1.SelectedNodeIndex = i.ToString() + ". " + j.ToString();
break;
}
}
}
用.net 2005改写后,现在TreeView1.SelectedNodeIndex好像没有用?
请各位大哥帮助一下
------解决方案--------------------http://blog.csdn.net/luq885/archive/2007/06/10/1646335.aspx
------解决方案-------------------- Dim NodeX As New TreeNode
NodeX = TreNNGdln.SelectedNode