Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我在列表中有 n 个员工姓名,让它成为
1 2 3 。. n
我想将此详细信息绑定到我的treeview1,例如
1 -2 --3 。. ----...n
如何做到这一点。任何人都可以为此粘贴代码提前谢谢 Amrutha
节点类应包含对父节点的引用,即:
public class Node { public Node parent; public Node(Node NewParent){ this.parent=NewParent; } }
除了根节点之外的所有节点都应该有一个节点作为父节点,对于根节点,父节点必须设置为空。