So I have the need to create a Tabbed MDI child window and see that there is a problem when the form that is associated with each tab has the docking property set to 'Fill'.
Essentially, the docking property really thinks it means 'fill' and as such the tabs are no longer available (the form is filling the entire MDI child window.)
I'm working in C# and below is my code:
private void formDocument_Load(object sender, System.EventArgs e) {
affinityRun = new formDataRun();
affinityRun.Parent = TabControl;
affinityRun.Dock = System.Windows.Forms.DockStyle.Fill;
Object x = TabControl.InsertItem(0, "Affinity", affinityRun.Handle.ToInt32(), 300);
desaltingRun = new formDataRun();
desaltingRun.Dock = System.Windows.Forms.DockStyle.Fill;
TabControl.InsertItem(1, "Desalting", desaltingRun.Handle.ToInt32(), 300);
TabControl.Icons = (XtremeSuiteControls.ImageManagerIcons)ImageManager.Icons;
TabControl.PaintManager.Positi on = XtremeSuiteControls.XTPTabPosition.xtpTabPositionLeft;
TabControl.PaintManager.Layout = XtremeSuiteControls.XTPTabLayoutStyle.xtpTabLayoutFixed;
}
the formDataRun is a simple Windows Form with an inner panel (the contents of which have been determined to be immaterial, through some testing.)
Everything looks okay if I remove the dock assignment, but it'll look pretty silly if the user maximizes the window and the inner panel stays the same size.
Anyone else run into this situation? Thanks in advance,
-djh
|