发新话题
打印

怎么样在树形节点的标题被选后将结果显示在lable上

怎么样在树形节点的标题被选后将结果显示在lable上

PHP代码里怎么样在树形视图的标题被选后将结果显示在lable上,这样:
复制内容到剪贴板
代码:
$this->Label1->Caption = $this->TreeView1->findNodeWithItemID($this->TreeView1->SelectedItemID)->Caption;
然后
复制内容到剪贴板
代码:
$currentNode = new TreeNode();
$currentNode = $this->TreeView1->findNodeWithItemID($this->TreeView1->SelectedItemID);
$this->Label1->Caption = $currentNode->Caption;
这样不行,$currentNode还是null,有人知道么,thx

TOP

不是这样用
引用:
$this->Label1->Caption
这样试一下
复制内容到剪贴板
代码:
$this->Label1->setCaption()
应该可以OK
一個偽裝成白癡的天纔!

TOP

发新话题