Last post Sep 29, 2010 07:22 AM by LarsBo
Sep 29, 2010 03:37 AM|LarsBo|LINK
I have a MySQL data at a web hotel. I can connect to the database from my web application hosted at the hotel . But trying to connect from a client application running on my PC fails using the same ConnetionString. The error is: Unable to connect to any of
the specified MySQL hosts
In fact the method below (the method is protected in the web application) fails in my client application but works in my web application.
private void button8_Click(object sender, EventArgs e)
string MyConString = "server=db.MYSITE.dk;user;" +
label1.Text = label1.Text + MyConString;
MySqlConnection connection = new MySqlConnection();
connection.ConnectionString = MyConString;
catch (MySqlException ex)
label7.Text = ex.Message;
I just tried to download WorkBench 5.2 and HeidiSQL, both connects to the database from my PC when supplying server and password information.
Any help that will allow me to connect to the database from my client application I much appreciated. I use connector 6.2.4
Sep 29, 2010 07:22 AM|LarsBo|LINK
I guess I have solved the issue. I tried with an old assembly 18.104.22.168 and got a compiler error with something like "cant use assembly in partial trust"
changing to fultrust gave me access to my database. Changing to the newer assembly in full trust also worked.
Now I just have to gain some understanding on security an d these trust levels.