1.form1为MDI父容器 IsMdiContainer = true;
2.使用tabStrip控件关联MDI子窗体.dock 为top
为什么打开 form2 :其中form 2的
MdiParent = form1
form2.WindowState = FormWindowState.Maximized;
后form2最上面的部分被tabStrip控件挡住了!!!!!!为什么呀??
tabStip设置如下:
this.tabStrip1.AutoSelectAttachedControl = true;
this.tabStrip1.CanReorderTabs = true;
this.tabStrip1.CloseButtonOnTabsVisible = true;
this.tabStrip1.CloseButtonVisible = true;
this.tabStrip1.Dock = System.Windows.Forms.DockStyle.Top;
this.tabStrip1.Location = new System.Drawing.Point(5, 155);
this.tabStrip1.MdiTabbedDocuments = true;
this.tabStrip1.Name = "tabStrip1";
this.tabStrip1.SelectedTab = this.tabItem1;
this.tabStrip1.ShowMdiChildIcon = false;
this.tabStrip1.Size = new System.Drawing.Size(674, 23);
this.tabStrip1.Style = DevComponents.DotNetBar.eTabStripStyle.Office2007Document;
this.tabStrip1.TabIndex = 2;
this.tabStrip1.TabLayoutType = DevComponents.DotNetBar.eTabLayoutType.FixedWithNavigationBox;
this.tabStrip1.Tabs.Add(this.tabItem1);
this.tabStrip1.Text = "tabStrip1";