Exemplo n.º 1
0
        /// <summary>  
        /// 分页控件回调函数  
        /// </summary>  
        /// <param name="pageNo">页码,由分页控件传入</param>
        /// <param name="pageSize">每页记录数</param>
        /// <returns></returns>  
        private void LoadPageData(int pageNo, int pageSize)  
        {
            nodeList.Items.Clear();
            List <string> nodes = new List <string>();

            if (dsType == "conflict")
            {
                grpHeader.Text = "ID重复的节点";
                nodes          = MyTrees.GetIdConflictNodes(pageNo, pageSize);
            }
            else if (dsType == "leaf")
            {
                grpHeader.Text = "孤立的叶子节点";
                nodes          = MyTrees.GetLeafAloneNodes(pageNo, pageSize).Values.ToList();
            }
            else if (dsType == "ring")
            {
                grpHeader.Text = "构成闭环的节点";
                nodes          = MyTrees.GetRingNodes(pageNo, pageSize).Values.ToList().ToList();
            }
            foreach (string node in nodes)
            {
                string[] nodeProp = node.Split(new String[] { "," }, StringSplitOptions.None);
                nodeList.Items.Add(nodeProp);
            }
        }