Public Class frmadminlogin

    Private Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click

        Dim Query = "SELECT `ACCOUNTSID` as id, `USERNAME` as `username`, `PASSWORD` as `password`, `USERTYPE` as `user_type` FROM `tblaccounts` WHERE `username`='" & TextBox1.Text & "' AND `password`='" & TextBox2.Text & "'"
        mySelectQuery(Query)
        
        Checkresult("adminLogin")
        
    End Sub

    Private Sub TextBox2_KeyDown(sender As Object, e As KeyEventArgs) Handles TextBox1.KeyDown, TextBox2.KeyDown
        If e.KeyCode = Keys.Enter Then
            Button2.PerformClick()
        End If
    End Sub

    Private Sub frmadminlogin_Load(sender As Object, e As EventArgs) Handles MyBase.Load

    End Sub
End Class