Code:
Sub Main()
'Splash Screen
'Becuase "Splash" is the chosen mode
'it will count down from 5 and dissapear on its own.
'"info will cause the splash screen to appear without
' the countdown.
Dim Splash As New frmSplash("Splash")
Splash.ShowDialog()
Application.DoEvents()
Splash.Dispose()
'Start up the Login screen
Dim Login As New frmLogin
Login.ShowDialog()
Application.DoEvents()
'Once the Login in finished, it checks for a valid
'user level and user name.
If Login.UserLevel <> "" Then
'if there is a user name, it calls the main form.
Dim MainForm As New frmMain(Login.UserName, Login.UserLevel)
Login.Dispose()
'I had to call this as a dialog to keep the subMain from quitting
MainForm.ShowDialog()
Else
'No valid user logged in. Probobly canceled out.
Login.Dispose()
End If
'End of subMain, program is over
End Sub
Anything glaringly wrong or that I could do better to load my app?