Click here to Skip to main content
15,904,024 members
Home / Discussions / C#
   

C#

 
AnswerRe: Password Pin
Nouman Bhatti4-Nov-07 19:18
Nouman Bhatti4-Nov-07 19:18 
QuestionCalender dayview Pin
NewToAspDotNet4-Nov-07 7:59
NewToAspDotNet4-Nov-07 7:59 
QuestionAdding A new Property To DataGridViewCell Pin
half-life4-Nov-07 7:44
half-life4-Nov-07 7:44 
QuestionCreating Web Service in C# Pin
kendo174-Nov-07 5:46
kendo174-Nov-07 5:46 
AnswerRe: Creating Web Service in C# Pin
pmarfleet4-Nov-07 6:13
pmarfleet4-Nov-07 6:13 
GeneralRe: Creating Web Service in C# Pin
kendo174-Nov-07 6:48
kendo174-Nov-07 6:48 
GeneralRe: Creating Web Service in C# Pin
kendo174-Nov-07 7:06
kendo174-Nov-07 7:06 
GeneralRe: Creating Web Service in C# Pin
pmarfleet4-Nov-07 7:09
pmarfleet4-Nov-07 7:09 
GeneralRe: Creating Web Service in C# Pin
pmarfleet4-Nov-07 7:07
pmarfleet4-Nov-07 7:07 
GeneralRe: Creating Web Service in C# Pin
kendo174-Nov-07 7:10
kendo174-Nov-07 7:10 
GeneralRe: Creating Web Service in C# Pin
pmarfleet4-Nov-07 7:14
pmarfleet4-Nov-07 7:14 
GeneralRe: Creating Web Service in C# [modified] Pin
kendo174-Nov-07 7:45
kendo174-Nov-07 7:45 
GeneralRe: Creating Web Service in C# Pin
pmarfleet4-Nov-07 7:59
pmarfleet4-Nov-07 7:59 
GeneralRe: Creating Web Service in C# Pin
kendo174-Nov-07 8:16
kendo174-Nov-07 8:16 
GeneralRe: Creating Web Service in C# Pin
pmarfleet4-Nov-07 8:19
pmarfleet4-Nov-07 8:19 
QuestionIntegrated two project in one Pin
Assaf824-Nov-07 4:00
Assaf824-Nov-07 4:00 
AnswerRe: Integrated two project in one Pin
Paul Conrad4-Nov-07 4:42
professionalPaul Conrad4-Nov-07 4:42 
GeneralRe: Integrated two project in one Pin
Anthony Mushrow4-Nov-07 4:58
professionalAnthony Mushrow4-Nov-07 4:58 
GeneralRe: Integrated two project in one Pin
Paul Conrad4-Nov-07 5:26
professionalPaul Conrad4-Nov-07 5:26 
GeneralRe: Integrated two project in one Pin
Assaf824-Nov-07 6:13
Assaf824-Nov-07 6:13 
GeneralRe: Integrated two project in one Pin
Paul Conrad4-Nov-07 6:21
professionalPaul Conrad4-Nov-07 6:21 
QuestionConnecting to remote MySQL database: cannot open connection Pin
mwholt4-Nov-07 2:48
mwholt4-Nov-07 2:48 
Hey - I'm trying to open a connection to a database hosted on my Unix server remotely:

private static void OpenSqlConnection()<br />
        {<br />
            MySqlConnection oMySqlConn = new MySqlConnection();<br />
<br />
            oMySqlConn.ConnectionString = "server=mydomain.com;database=uname_main;user id=uname_main;pwd=myPwd;pooling=false;port=3306;";<br />
<br />
<br />
<br />
            try<br />
            {<br />
<br />
                oMySqlConn.Open();<br />
<br />
                if (oMySqlConn.State == ConnectionState.Open) MessageBox.Show("Connection to MySQL opened through OLE DB Provider");<br />
<br />
                oMySqlConn.Close();<br />
<br />
            }<br />
            <br />
            catch (MySqlException ex)<br />
            {<br />
<br />
                MessageBox.Show(ex.Number + " - " + ex.Message, "DB-Connection");<br />
<br />
            } <br />
            <br />
<br />
        }


Everything works fine (as in, I'm using all required libraries, such as MySQL.Data/MySQL.Data.MySQLClient) and I get no errors until I run this method. After about 8 seconds, it constantly says:

1042 - Unable to connect to any of the specified MySQL hosts.

I'm positive that my domain name is correct and that all login credentials are correct. In CPanel on my server I've added %, %.%.%.%, and my IP address as access hosts and I still can't seem to open the connection.

I've been working on this for hours but to no avail, and online help has proved not useful so far.

Any suggestions? I'd gladly appreciate some!

-Matt
GeneralRe: Connecting to remote MySQL database: cannot open connection Pin
mwholt4-Nov-07 2:54
mwholt4-Nov-07 2:54 
AnswerRe: Connecting to remote MySQL database: cannot open connection Pin
Guffa4-Nov-07 3:41
Guffa4-Nov-07 3:41 
GeneralRe: Connecting to remote MySQL database: cannot open connection Pin
mwholt4-Nov-07 8:28
mwholt4-Nov-07 8:28 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.