예제 #1
0
 private void updateTipsBox(MyNode node)
 {
     try
     {
         StringBuilder builder = new StringBuilder();
         builder.Append(node.InsertInfo);
         builder.AppendLine();
         builder.AppendLine();
         builder.AppendLine(node.Tips);
         this.textBox1.Text = builder.ToString();
     }
     catch (Exception)
     {
         this.textBox1.Text = "";
     }
 }
예제 #2
0
 private TreeNode builtTree(XmlElement xe)
 {
     MyNode node = new MyNode {
         Description = xe.GetAttribute("des"),
         InsertInfo = xe.GetAttribute("insertInfo"),
         Tips = xe.GetAttribute("tips")
     };
     if (xe.ChildNodes != null)
     {
         foreach (XmlElement element in xe.ChildNodes)
         {
             node.Nodes.Add(this.builtTree(element));
         }
     }
     return node;
 }