TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Erdinc Kolukisa
NA
113
0
connecting to MySQL via Network
Sep 22 2010 9:23 AM
hi guys..i am trying to connect to a database in the other computer which is in network...i should do it by using MySql..to do that i installed MySqlConnector for .Net in my pc and referenced it to my program and coded like below in try catch block
MySqlConnection
connect =
new
MySqlConnection
(
"server=pcname/Localhost;database=dbname;uid=a;pwd=b"
);
connect.Open();
Console
.WriteLine(
"Baglanti Durumu : {0}"
,
connect.State);
connect.Close();
and i am getting such an error "Unable to connect to any of the specified MySQL hosts "
so what can i do to get rid off that error...i am not sure about my connection string because i am working with MySql for the first time..and i am not sure if the settings are done correctly
can u help pls ? where is my mistake ?
Reply
Answers (
5
)
Exporting Gridview to Excel that has subtotals
loading database into checlistbox