MDI restoring problem
-
Thursday, February 23, 2012 2:12 PM
Dears,
I have an MDI app conatining one form in maxmizing size when try to close this form its first restore to normal size then close
i want to remove this Behavior
All Replies
-
Thursday, February 23, 2012 2:43 PM
Hi R.Hussein
Your problem is not really clear.
But if you want that your form will be maximized when loading so:
1-Under the toolstrip clik when you want to show the form you must have this line(in the MdiParent):
Private Sub ContentsToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ContentsToolStripMenuItem.Click Form1.MdiParent = Me Form1.Show() End Sub
2-You maximize your form when loading it(Form1):
Private Sub Form1_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load Me.WindowState = FormWindowState.Maximized End Sub
Regards
Best Regards...Please mark as answer if my post is helpful http://yosr-jemili.blogspot.com
- Edited by YosrJ Thursday, February 23, 2012 2:44 PM
-
Friday, February 24, 2012 8:19 AMModeratorHi R.Hussein,
Could you please show us part of the code because I cannot reproduce the issue?
Best Regards,Bob Wu [MSFT]
MSDN Community Support | Feedback to us
-
Sunday, February 26, 2012 9:03 AM
dear YosrJ,
my problem is when try to close the child form its firstly restore to normal size then close something of flikering
-
Tuesday, February 28, 2012 8:34 AMModerator
Hi R.Hussein,dear YosrJ,
my problem is when try to close the child form its firstly restore to normal size then close something of flikering
By default, the mdi child form will not restore to normal size when you close it, could you please share the code here?
Best Regards,
Bob Wu [MSFT]
MSDN Community Support | Feedback to us
-
Sunday, March 04, 2012 1:16 PM
Dears:
I think my problem happens here.
protected override void Dispose ( bool disposing )
{
if ( !disposed )
{
if ( disposing )
{
if ( ctrValidateForm != null ) ctrValidateForm.Dispose();
if ( _vSecurity != null ) _vSecurity.Dispose();
if ( FormControls != null ) FormControls.Dispose();
if ( MyTransaction != null ) MyTransaction.Dispose();
}
// shared cleanup logic
disposed = true;
}
base.Dispose(disposing);
}I found that windowstatus changed in (base.Dispose(disposing)) statement to be normal


