Hello everyone,
I'm writing up a new application that instead of using microsoft as a server, I'm using a linux server with a database in it. The database was setup, the tables were set up, and access was granted in mysql. The issue I'm having is that I keep getting an error message with error 25 stating that "A network related or instance specific error occurred." then it goes down to say error -25 connection string is not valid. This is the connection method that I am utilizing:
On Error GoTo errorhandler
Dim con As New SqlClient.SqlConnection("server=192.168.0.23:3306; database=test; user ID=root;Password=password;Integrated Security=true;")
Dim cmd As SqlCommand
cmd = New SqlCommand("SELECT * FROM students", con)
Dim da As SqlDataAdapter
Dim ds As DataSet
da = New SqlDataAdapter(cmd)
ds = New DataSet
da.Fill(ds, "students")
MsgBox(ds)
con.Open()
DataGridView1.DataSource = ds.Tables("students").DefaultView
con.Close()
Exit Sub
errorhandler:
MsgBox(Err.Description, vbExclamation)
Does anyone have an idea as to why this is not working? Or, how to get this working? I would greatly appreciate it.