How do I combine 2 programs - Programmers Heaven

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.

How do I combine 2 programs

BadDog5150BadDog5150 Posts: 2Member
Please forgive my ignorance, I suspect my question has a very simple answer, but I can't find it in the books I have. I started teaching myself using VB2008 express about 3 days ago.
I have a cool web browser and a small simple password prog. I want to activate the browser when the correct username and password is given.
This is the code for the password prog.


Public Class Form1

Private Sub OKButton_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles OKButton.Click
If usernameBox.Text = "apress" And _
passwordBox.Text = "noidea" Then

If UsernameBox.Text = "123" And _
PasswordBox.Text = "456" Then

MessageBox.Show("Welcome! You're logged in")
Else
MessageBox.Show("Sorry, try again")
End If

Else
MessageBox.Show("Sorry, try again")
End If

End Sub
End Class

I don't know the syntax or the correct command to do what I want. Please help.
Sign In or Register to comment.