示例#1
0
        private void btnphieuthu_ItemClick(object sender, ItemClickEventArgs e)
        {
            frm_PhieuThu f = new frm_PhieuThu();

            f.MdiParent = this;
            f.Show();
        }
示例#2
0
        //private void VisibleMenu(ArrayList Roles, RibbonControl ribControl)
        //{
        //    foreach (RibbonPage ribPage in ribControl.Pages)
        //    {
        //        int PageGroup = 0;
        //        foreach (RibbonPageGroup ribPageGroup in ribPage.Groups)
        //        {
        //            int CountBarItem = 0;
        //            foreach (BarItemLink barItem in ribPageGroup.ItemLinks)
        //            {
        //                if (barItem.GetType() == typeof(BarSubItemLink))
        //                {
        //                    BarSubItemLink bsi = (BarSubItemLink)(barItem);
        //                    foreach (BarItemLink barItemLink in bsi.VisibleLinks)
        //                    {
        //                        foreach (String strValue in barItemLink.Item.Tag.ToString().Split('|'))
        //                        {
        //                            if (Roles.Contains(strValue))
        //                            {
        //                                barItemLink.Item.Visibility = BarItemVisibility.Always;
        //                                PageGroup = 1;
        //                                CountBarItem = 1;

        //                            }
        //                        }
        //                    }
        //                    if (CountBarItem == 1)
        //                    {
        //                        barItem.Item.Visibility = BarItemVisibility.Always;
        //                        PageGroup = 1;
        //                    }


        //                }
        //                else
        //                {
        //                    if (Roles.Contains(barItem.Item.Tag))
        //                    {
        //                        barItem.Item.Visibility = BarItemVisibility.Always;
        //                        PageGroup = 1;
        //                    }
        //                }
        //            }
        //            if (PageGroup == 1)
        //            {
        //                ribPage.Visible = true;
        //                ribPageGroup.Visible = true;
        //            }
        //        }
        //    }
        //}


        private void btnphieuthu_ItemClick(object sender, ItemClickEventArgs e)
        {
            frm_PhieuThu f = new frm_PhieuThu();

            if (ExistForm(f))
            {
                return;
            }
            f.MdiParent = this;
            f.Show();
        }