예제 #1
0
        private void TabCreating(DevExpress.XtraTab.XtraTabControl tabControl, string Text, string Name, UserControl uc, DevExpress.XtraNavBar.NavBarLinkEventArgs e)
        {
            int index = CheckTabExits(tabControl, Name);

            if (index >= 0)
            {
                tabControl.TabPages[index].PageVisible = true;
                tabControl.SelectedTabPage             = tabControl.TabPages[index];
                tabControl.SelectedTabPage.Text        = Text;
                uc.Dispose();
                uc = null;
            }
            else
            {
                DevExpress.XtraTab.XtraTabPage tabpage = new DevExpress.XtraTab.XtraTabPage {
                    Text = Text, Name = Name, ImageIndex = 0
                };
                tabpage.Image = e.Link.Item.SmallImage;
                tabControl.TabPages.Add(tabpage);
                tabControl.SelectedTabPage = tabpage;

                //uc.TopLevel = false;
                uc.Parent = tabpage;
                uc.Show();
                uc.Dock = DockStyle.Fill;
            }
        }
예제 #2
0
        private void xtraTabControl_GiaoDien_CloseButtonClick_1(object sender, EventArgs e)
        {
            DevExpress.XtraTab.XtraTabControl xtab = (DevExpress.XtraTab.XtraTabControl)sender;
            int i = xtab.SelectedTabPageIndex;

            xtab.TabPages.RemoveAt(xtab.SelectedTabPageIndex);
            xtab.SelectedTabPageIndex = i;
        }
예제 #3
0
 public bool tabControlCheckHave(DevExpress.XtraTab.XtraTabControl tab, String tabName)
 {
     for (int i = 0; i < tab.TabPages.Count; i++)
     {
         if (tab.TabPages[i].Text == tabName)
         {
             tab.SelectedTabPageIndex = i;
             return(true);
         }
     }
     return(false);
 }
예제 #4
0
        private void xtraTabControl1_CloseButtonClick(object sender, EventArgs e)
        {
            DevExpress.XtraTab.XtraTabControl xtab = (DevExpress.XtraTab.XtraTabControl)sender;
            if (xtab.TabPages.Count == 1)
            {
                return;
            }
            int i = xtab.SelectedTabPageIndex;

            xtab.TabPages.RemoveAt(xtab.SelectedTabPageIndex);
            xtab.SelectedTabPageIndex = i - 1;
        }
예제 #5
0
        static int CheckTabExits(DevExpress.XtraTab.XtraTabControl tabControlName, string tabName)
        {
            int re = -1;

            for (int i = 0; i < tabControlName.TabPages.Count; i++)
            {
                if (tabControlName.TabPages[i].Name == tabName)
                {
                    re = i;
                    break;
                }
            }
            return(re);
        }
예제 #6
0
 private void InitializeComponent()
 {
     this.tabControl1 = new DevExpress.XtraTab.XtraTabControl();
     this.tbpCommon = new DevExpress.XtraTab.XtraTabPage();
     this.groupBox1 = new DevExpress.XtraEditors.GroupControl();
     this.lblEndInfo = new System.Windows.Forms.Label();
     this.chkStaff = new System.Windows.Forms.CheckBox();
     this.chkReSel = new System.Windows.Forms.CheckBox();
     this.cmbPoscond = new System.Windows.Forms.ComboBox();
     this.cmbActdef = new System.Windows.Forms.ComboBox();
     this.List_PreStaff = new System.Windows.Forms.ListBox();
     this.cmbStaff = new System.Windows.Forms.ComboBox();
     this.lblReSel = new System.Windows.Forms.Label();
     this.Label4 = new System.Windows.Forms.Label();
     this.Label2 = new System.Windows.Forms.Label();
     this.Lbl_TS = new System.Windows.Forms.Label();
     ((System.ComponentModel.ISupportInitialize)(this.tabControl1)).BeginInit();
     this.tabControl1.SuspendLayout();
     this.tbpCommon.SuspendLayout();
     ((System.ComponentModel.ISupportInitialize)(this.groupBox1)).BeginInit();
     this.groupBox1.SuspendLayout();
     this.SuspendLayout();
     //
     // btCancel
     //
     this.btCancel.Location = new System.Drawing.Point(200, 291);
     //
     // btOk
     //
     this.btOk.Location = new System.Drawing.Point(104, 291);
     //
     // tabControl1
     //
     this.tabControl1.Font = new System.Drawing.Font("SimSun", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
     this.tabControl1.Location = new System.Drawing.Point(8, 8);
     this.tabControl1.Name = "tabControl1";
     this.tabControl1.SelectedTabPage = this.tbpCommon;
     this.tabControl1.Size = new System.Drawing.Size(376, 272);
     this.tabControl1.TabIndex = 2;
     this.tabControl1.TabPages.AddRange(new DevExpress.XtraTab.XtraTabPage[] {
     this.tbpCommon});
     //
     // tbpCommon
     //
     this.tbpCommon.Appearance.PageClient.ForeColor = System.Drawing.SystemColors.ControlText;
     this.tbpCommon.Appearance.PageClient.Options.UseForeColor = true;
     this.tbpCommon.Controls.Add(this.groupBox1);
     this.tbpCommon.Font = new System.Drawing.Font("SimSun", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
     this.tbpCommon.Name = "tbpCommon";
     this.tbpCommon.Size = new System.Drawing.Size(367, 240);
     this.tbpCommon.Text = "一般转出";
     //
     // groupBox1
     //
     this.groupBox1.Controls.Add(this.lblEndInfo);
     this.groupBox1.Controls.Add(this.chkStaff);
     this.groupBox1.Controls.Add(this.chkReSel);
     this.groupBox1.Controls.Add(this.cmbPoscond);
     this.groupBox1.Controls.Add(this.cmbActdef);
     this.groupBox1.Controls.Add(this.List_PreStaff);
     this.groupBox1.Controls.Add(this.cmbStaff);
     this.groupBox1.Controls.Add(this.lblReSel);
     this.groupBox1.Controls.Add(this.Label4);
     this.groupBox1.Controls.Add(this.Label2);
     this.groupBox1.Controls.Add(this.Lbl_TS);
     this.groupBox1.Location = new System.Drawing.Point(8, 8);
     this.groupBox1.Name = "groupBox1";
     this.groupBox1.Size = new System.Drawing.Size(352, 192);
     this.groupBox1.TabIndex = 0;
     this.groupBox1.Text = "请选择下一步经办人";
     //
     // lblEndInfo
     //
     this.lblEndInfo.AutoSize = true;
     this.lblEndInfo.Font = new System.Drawing.Font("SimSun", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
     this.lblEndInfo.ForeColor = System.Drawing.Color.Magenta;
     this.lblEndInfo.Location = new System.Drawing.Point(118, 174);
     this.lblEndInfo.Name = "lblEndInfo";
     this.lblEndInfo.Size = new System.Drawing.Size(135, 12);
     this.lblEndInfo.TabIndex = 22;
     this.lblEndInfo.Text = "选择该条件业务将结案";
     //
     // chkStaff
     //
     this.chkStaff.BackColor = System.Drawing.Color.Transparent;
     this.chkStaff.Cursor = System.Windows.Forms.Cursors.Default;
     this.chkStaff.Font = new System.Drawing.Font("SimSun", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
     this.chkStaff.ForeColor = System.Drawing.SystemColors.WindowText;
     this.chkStaff.Location = new System.Drawing.Point(22, 72);
     this.chkStaff.Name = "chkStaff";
     this.chkStaff.RightToLeft = System.Windows.Forms.RightToLeft.No;
     this.chkStaff.Size = new System.Drawing.Size(112, 18);
     this.chkStaff.TabIndex = 17;
     this.chkStaff.Text = "下一步经办人:";
     this.chkStaff.UseVisualStyleBackColor = false;
     //
     // chkReSel
     //
     this.chkReSel.BackColor = System.Drawing.Color.Transparent;
     this.chkReSel.Cursor = System.Windows.Forms.Cursors.Default;
     this.chkReSel.Enabled = false;
     this.chkReSel.ForeColor = System.Drawing.SystemColors.ControlText;
     this.chkReSel.Location = new System.Drawing.Point(310, 23);
     this.chkReSel.Name = "chkReSel";
     this.chkReSel.RightToLeft = System.Windows.Forms.RightToLeft.No;
     this.chkReSel.Size = new System.Drawing.Size(16, 21);
     this.chkReSel.TabIndex = 16;
     this.chkReSel.UseVisualStyleBackColor = false;
     this.chkReSel.Visible = false;
     //
     // cmbPoscond
     //
     this.cmbPoscond.BackColor = System.Drawing.SystemColors.Window;
     this.cmbPoscond.Cursor = System.Windows.Forms.Cursors.Default;
     this.cmbPoscond.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
     this.cmbPoscond.ForeColor = System.Drawing.SystemColors.WindowText;
     this.cmbPoscond.Location = new System.Drawing.Point(142, 23);
     this.cmbPoscond.Name = "cmbPoscond";
     this.cmbPoscond.RightToLeft = System.Windows.Forms.RightToLeft.No;
     this.cmbPoscond.Size = new System.Drawing.Size(155, 20);
     this.cmbPoscond.TabIndex = 15;
     //
     // cmbActdef
     //
     this.cmbActdef.BackColor = System.Drawing.SystemColors.Window;
     this.cmbActdef.Cursor = System.Windows.Forms.Cursors.Default;
     this.cmbActdef.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
     this.cmbActdef.ForeColor = System.Drawing.SystemColors.WindowText;
     this.cmbActdef.Location = new System.Drawing.Point(142, 47);
     this.cmbActdef.Name = "cmbActdef";
     this.cmbActdef.RightToLeft = System.Windows.Forms.RightToLeft.No;
     this.cmbActdef.Size = new System.Drawing.Size(155, 20);
     this.cmbActdef.TabIndex = 14;
     //
     // List_PreStaff
     //
     this.List_PreStaff.BackColor = System.Drawing.SystemColors.Menu;
     this.List_PreStaff.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
     this.List_PreStaff.Cursor = System.Windows.Forms.Cursors.Default;
     this.List_PreStaff.ForeColor = System.Drawing.Color.Blue;
     this.List_PreStaff.ItemHeight = 12;
     this.List_PreStaff.Location = new System.Drawing.Point(142, 97);
     this.List_PreStaff.Name = "List_PreStaff";
     this.List_PreStaff.RightToLeft = System.Windows.Forms.RightToLeft.No;
     this.List_PreStaff.Size = new System.Drawing.Size(155, 62);
     this.List_PreStaff.Sorted = true;
     this.List_PreStaff.TabIndex = 13;
     this.List_PreStaff.Visible = false;
     //
     // cmbStaff
     //
     this.cmbStaff.BackColor = System.Drawing.SystemColors.Window;
     this.cmbStaff.Cursor = System.Windows.Forms.Cursors.Default;
     this.cmbStaff.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
     this.cmbStaff.ForeColor = System.Drawing.SystemColors.WindowText;
     this.cmbStaff.Location = new System.Drawing.Point(142, 71);
     this.cmbStaff.Name = "cmbStaff";
     this.cmbStaff.RightToLeft = System.Windows.Forms.RightToLeft.No;
     this.cmbStaff.Size = new System.Drawing.Size(155, 20);
     this.cmbStaff.TabIndex = 12;
     //
     // lblReSel
     //
     this.lblReSel.BackColor = System.Drawing.Color.Transparent;
     this.lblReSel.Cursor = System.Windows.Forms.Cursors.Default;
     this.lblReSel.Enabled = false;
     this.lblReSel.ForeColor = System.Drawing.Color.Blue;
     this.lblReSel.Location = new System.Drawing.Point(310, 47);
     this.lblReSel.Name = "lblReSel";
     this.lblReSel.RightToLeft = System.Windows.Forms.RightToLeft.No;
     this.lblReSel.Size = new System.Drawing.Size(20, 96);
     this.lblReSel.TabIndex = 21;
     this.lblReSel.Text = "重新选择条件";
     this.lblReSel.Visible = false;
     //
     // Label4
     //
     this.Label4.AutoSize = true;
     this.Label4.BackColor = System.Drawing.Color.Transparent;
     this.Label4.Cursor = System.Windows.Forms.Cursors.Default;
     this.Label4.Font = new System.Drawing.Font("SimSun", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
     this.Label4.ForeColor = System.Drawing.SystemColors.ControlText;
     this.Label4.Location = new System.Drawing.Point(48, 27);
     this.Label4.Name = "Label4";
     this.Label4.RightToLeft = System.Windows.Forms.RightToLeft.No;
     this.Label4.Size = new System.Drawing.Size(77, 12);
     this.Label4.TabIndex = 20;
     this.Label4.Text = "转下步条件:";
     //
     // Label2
     //
     this.Label2.AutoSize = true;
     this.Label2.BackColor = System.Drawing.Color.Transparent;
     this.Label2.Cursor = System.Windows.Forms.Cursors.Default;
     this.Label2.Font = new System.Drawing.Font("SimSun", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
     this.Label2.ForeColor = System.Drawing.SystemColors.ControlText;
     this.Label2.Location = new System.Drawing.Point(48, 52);
     this.Label2.Name = "Label2";
     this.Label2.RightToLeft = System.Windows.Forms.RightToLeft.No;
     this.Label2.Size = new System.Drawing.Size(77, 12);
     this.Label2.TabIndex = 19;
     this.Label2.Text = "下一步工作:";
     //
     // Lbl_TS
     //
     this.Lbl_TS.BackColor = System.Drawing.Color.Transparent;
     this.Lbl_TS.Cursor = System.Windows.Forms.Cursors.Default;
     this.Lbl_TS.Font = new System.Drawing.Font("SimSun", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
     this.Lbl_TS.ForeColor = System.Drawing.SystemColors.ControlText;
     this.Lbl_TS.Location = new System.Drawing.Point(54, 98);
     this.Lbl_TS.Name = "Lbl_TS";
     this.Lbl_TS.RightToLeft = System.Windows.Forms.RightToLeft.No;
     this.Lbl_TS.Size = new System.Drawing.Size(78, 48);
     this.Lbl_TS.TabIndex = 18;
     this.Lbl_TS.Text = "提示:                上几步经办人见右列表";
     this.Lbl_TS.Visible = false;
     //
     // PassDialog
     //
     this.AutoScaleBaseSize = new System.Drawing.Size(6, 15);
     this.ClientSize = new System.Drawing.Size(392, 325);
     this.Controls.Add(this.tabControl1);
     this.LookAndFeel.UseDefaultLookAndFeel = false;
     this.Name = "PassDialog";
     this.Controls.SetChildIndex(this.btOk, 0);
     this.Controls.SetChildIndex(this.btCancel, 0);
     this.Controls.SetChildIndex(this.tabControl1, 0);
     ((System.ComponentModel.ISupportInitialize)(this.tabControl1)).EndInit();
     this.tabControl1.ResumeLayout(false);
     this.tbpCommon.ResumeLayout(false);
     ((System.ComponentModel.ISupportInitialize)(this.groupBox1)).EndInit();
     this.groupBox1.ResumeLayout(false);
     this.groupBox1.PerformLayout();
     this.ResumeLayout(false);
 }