Ok, I am pretty new to VB.Net and I am having some trouble with loading a child form into a Mdi form as Maximized. The form appears to be in the maximized state, but the child form does not fill the entire area unless i minimize it and maximize it again.
I set the properties of the shild form to WindowState - Maximized and also set it on load like so
VB Code:
Private Sub lnkAdmin_LinkClicked(ByVal sender As System.Object, ByVal e As System.Windows.Forms.LinkLabelLinkClickedEventArgs) Handles lnkAdmin.LinkClicked If pnlAdmin.Visible = False Then pnlAdmin.Visible = True picSamples.Top = picSamples.Top + 25 lnkSamples.Top = lnkSamples.Top + 25 pnlSamples.Top = pnlSamples.Top + 25 lnkReporting.Top = lnkReporting.Top + 25 picReporting.Top = picReporting.Top + 25 pnlReporting.Top = pnlReporting.Top + 25 picExit.Top = picExit.Top + 25 lnkExit.Top = lnkExit.Top + 25 frmAdminHelp.MdiParent = Me 'here is where i set the mdi parent frmAdminHelp.WindowState = FormWindowState.Maximized 'Set maximized frmAdminHelp.Show() Else pnlAdmin.Visible = False picSamples.Top = picSamples.Top - 25 lnkSamples.Top = lnkSamples.Top - 25 pnlSamples.Top = pnlSamples.Top - 25 lnkReporting.Top = lnkReporting.Top - 25 picReporting.Top = picReporting.Top - 25 pnlReporting.Top = pnlReporting.Top - 25 picExit.Top = picExit.Top - 25 lnkExit.Top = lnkExit.Top - 25 frmAdminHelp.Dispose() End If End Sub






Reply With Quote