Login Register






C#, connect to MySQL database filter_list
Author
Message
RE: C#, connect to MySQL database #2
(11-18-2016, 04:32 PM)Skryptec Wrote: Hello,

I've installed the MySql.ConnectorNET.Data package and even some others to test.

       
Code:
           MySql.Data.MySqlClient.MySqlConnection conn;            string myConnectionString;            myConnectionString = "server=sql212.ihostfull.com;uid=uoolo_lolno;" +                "pwd=lolno;database=uoolo_lolno_test;";            try            {                conn = new MySql.Data.MySqlClient.MySqlConnection();                conn.ConnectionString = myConnectionString;                conn.Open();                MessageBox.Show("This shit finally working.");            }            catch (MySql.Data.MySqlClient.MySqlException ex)            {                MessageBox.Show(ex.Message);            }

Problem is, it doesn't work.
It returns this error.
Code:
Unable to connect to any of the specified MySQL hosts.

Does anyone know how to fix it?

I literally copied it from here and it doesn't work.
https://dev.mysql.com/doc/connector-net/...-open.html

Everything seems ok.
Does the mySQL server allow your user to access it from your ip address?

Reply





Messages In This Thread
C#, connect to MySQL database - by Skryptec - 11-18-2016, 04:32 PM
RE: C#, connect to MySQL database - by Pikami - 11-18-2016, 04:37 PM
RE: C#, connect to MySQL database - by Skryptec - 11-18-2016, 04:38 PM
RE: C#, connect to MySQL database - by Pikami - 11-18-2016, 04:41 PM
RE: C#, connect to MySQL database - by Skryptec - 11-18-2016, 04:43 PM
RE: C#, connect to MySQL database - by Pikami - 11-18-2016, 04:51 PM
RE: C#, connect to MySQL database - by Skryptec - 11-18-2016, 04:52 PM
RE: C#, connect to MySQL database - by Pikami - 11-18-2016, 04:54 PM
RE: C#, connect to MySQL database - by Skryptec - 11-18-2016, 04:56 PM
RE: C#, connect to MySQL database - by fuhrer - 11-18-2016, 10:34 PM
RE: C#, connect to MySQL database - by Skryptec - 11-19-2016, 12:23 AM
RE: C#, connect to MySQL database - by AlexaHawk - 02-19-2017, 02:05 AM