Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- conn = New MySqlConnection
- conn.ConnectionString = "server=SERVER.COM;Port=3306; user id=USERID; password=PASSWORD; database=DATABASE"
- Try
- conn.Open()
- Dim sqlquery = "SELECT * From Users WHERE username='" & textbox1.text & "'"
- Dim command As New MySqlCommand
- Dim adapter As New MySqlDataAdapter
- Dim data As MySqlDataReader
- command.Connection = conn
- command.CommandText = sqlquery
- adapter.SelectCommand = command
- data = command.ExecuteReader
- catch ex as exception
- msgbox(ex.message)
- end try
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement