BP Forums
Issue with Visual Basic Express Programming: - Printable Version

+- BP Forums (https://bpforums.info)
+-- Forum: Archived Forums (https://bpforums.info/forumdisplay.php?fid=55)
+--- Forum: Archived Forums (https://bpforums.info/forumdisplay.php?fid=56)
+---- Forum: Computing (https://bpforums.info/forumdisplay.php?fid=12)
+---- Thread: Issue with Visual Basic Express Programming: (/showthread.php?tid=615)



Issue with Visual Basic Express Programming: - Zantox - 08-26-2012

So I have 3 forms inside a project:
1: Login
2: Launchpad
3: Irrelevant but: About

The first one that comes up upon start is "Login"
It has 2 text box forms, with "Username" and "Password"
and then a login button (See code Below)

My problem is, I have it set to if the login information is correct, close the "Login" window and open the "Launchpad" Form. And what happens is, when I fill it out correctly, and click login, it opens launchpad really fast and then closes everything. Please help.

Code:
If TextBox1.Text = "a" And TextBox2.Text = "a" Then
            Launchpad.Show()
            Me.Close()
        Else : MsgBox("You have specified an Incorrect Username or Password, Please Try Again. If problems still persist, please contact Support.")
        End If



Re: Issue with Visual Basic Express Programming: - xolara - 08-27-2012

You have to change the application Properties (Alt-Enter)

and go under the tab Application (The very first one)

Now find the drop down box with the label above it saying: Shutdown mode

now change that from: when startup form closes

to: when last form closes

[attachment=0]<!-- ia0 -->4.png<!-- ia0 -->[/attachment]


Re: Issue with Visual Basic Express Programming: - Zantox - 08-27-2012

That did it! Thanks so much for your help! <!-- sSmile --><img src="{SMILIES_PATH}/icon_e_smile.gif" alt="Smile" title="Smile" /><!-- sSmile -->


Re: Issue with Visual Basic Express Programming: - xolara - 08-27-2012

No problem!