Question Why forms are distorted for a second when launched?

zaurb

New member
Joined
Nov 26, 2008
Messages
2
Programming Experience
Beginner
Hello!

When I start forms within mdi form for an instance the form is shown distorted and like flying in from the left top angle within the mdi form:
<img src="http://img401.imageshack.us/img401/4854/whenstarted.png" border="0" alt="Image Hosting"></a>

after a second it becomes normal:
normal.png


How can I fix this?


It happens with forms, that are inherited from another form. Here's the Show() code that starts the form:

VB.NET:
Public Sub ShowForm(ByVal fForm As Form)
        Dim objForms As Form
        For Each objForms In Me.MdiChildren
            If objForms.Name = fForm.Name Then
                fForm.Activate()
                fForm = Nothing
                objForms.Focus()
                Return
            End If
        Next
        With fForm
 
            If fForm.Name <> "Home" And fForm.Name <> "LoginForm1" Then
                .MdiParent = Me
                .StartPosition = FormStartPosition.CenterScreen
                .WindowState = FormWindowState.Maximized
                .ShowIcon = False
                .Show()
            Else
                .MdiParent = Me
                .StartPosition = FormStartPosition.CenterScreen
                .WindowState = FormWindowState.Normal
                .Show()
            End If


Here're the properties of appBase - the base form from which other forms are inherited:
appbasebaseform.png



here is the inherited form:

vascheinheritedform.png


here're the inherited forms properties:
vascheproperties.png
 
Back
Top