[Help] remote sql connection
k, i'v been searching, and trying so many things and not comingup with any way of doing this.
basicly, i want it to do this.
button clicked:
--username.txt to a string
--password.txt to a string
open remote connection with username and password to remote connection
if sucsessfull, msgbox "hello world"
if not, msgbox "error"
thats it.
this is what i'v got...most complete code...
anybody tell me where im going wrong?
basicly, i want it to do this.
button clicked:
--username.txt to a string
--password.txt to a string
open remote connection with username and password to remote connection
if sucsessfull, msgbox "hello world"
if not, msgbox "error"
thats it.
this is what i'v got...most complete code...
Code:
Private Sub Login_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles OK.Click
conn = New MySqlConnection()
conn.ConnectionString = "server=" & "server IP" & ";" _
& "user id=" & txtUsername.Text & ";" _
& "password=" & txtPassword.Text & ";" _
& "database= usertable"
Try
conn.Open()
MessageBox.Show("user accepted, application starting")
conn.Close()
frmbrowser.show()
me.close()
Catch myerror As MySqlException
MessageBox.Show("incorrect password")
Finally
conn.Dispose()
End Try
End Sub

.