コード例 #1
0
        private void tvBranches_AfterCheck(object sender, TreeViewEventArgs e)
        {
            TriStateTreeView.getStatus(e);

            clbState.Items.Clear();
            clbDistrict.Items.Clear();
            clbMandal.Items.Clear();
            clbVillage.Items.Clear();
            GetSelectedValues();

            tvBranches.BeginUpdate();

            foreach (TreeNode Node in e.Node.Nodes)
            {
                Node.Checked = e.Node.Checked;
            }

            tvBranches.EndUpdate();

            sChkComp = "";
            sChkBran = "";


            bool iscomp = false;

            for (int i = 0; i < tvBranches.Nodes.Count; i++)
            {
                for (int j = 0; j < tvBranches.Nodes[i].Nodes.Count; j++)
                {
                    for (int k = 0; k < tvBranches.Nodes[i].Nodes[j].Nodes.Count; k++)
                    {
                        if (tvBranches.Nodes[i].Nodes[j].Nodes[k].Checked == true)
                        {
                            if (sChkBran != string.Empty)
                            {
                                sChkBran += ",";
                            }
                            sChkBran += "'" + tvBranches.Nodes[i].Nodes[j].Nodes[k].Name.ToString() + "'";
                            iscomp    = true;
                        }
                    }

                    if (iscomp == true)
                    {
                        if (sChkComp != string.Empty)
                        {
                            sChkComp += ",";
                        }
                        sChkComp += "'" + tvBranches.Nodes[i].Nodes[j].Name.ToString() + "'";
                    }
                    iscomp = false;
                }
            }

            FillStates(sChkComp, sChkBran, sChkDocMonth);
            FillCampGroups(Company, Branches, DocumentMonth);
        }
コード例 #2
0
        private void tvBranches_AfterCheck(object sender, TreeViewEventArgs e)
        {
            TriStateTreeView.getStatus(e);
            tvBranches.BeginUpdate();

            foreach (TreeNode Node in e.Node.Nodes)
            {
                Node.Checked = e.Node.Checked;
            }

            tvBranches.EndUpdate();
        }
コード例 #3
0
 private void treeView1_AfterCheck(object sender, TreeViewEventArgs e)
 {
     //treeView1.Update();
     TriStateTreeView.getStatus(e);
 }
コード例 #4
0
 private void tvBranches_AfterCheck(object sender, TreeViewEventArgs e)
 {
     TriStateTreeView.getStatus(e);
 }
コード例 #5
0
 private void tvDocMonth_AfterCheck(object sender, TreeViewEventArgs e)
 {
     TriStateTreeView.getStatus(e);
 }