Search for software
Im just trying to open a new form and close the current form, its pretty simple but im new in vb
code:
Public Class Form1
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Dim login = Me.UserpasswordTableAdapter1.usernamepas¦ textpassword.Text)
If login Is Nothing Then
MsgBox("incorrect details")
Else : Form2.Show()
End If
If Form2.Show Then
Me.Hide()
End If
End Sub
|
Jay |
Make an event for when the current form closes, and make it so that if the login is correct then the current form will close and on in that close event for the current form make it so that the other form shows. |
Other Questions & Answers
|