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
Akashkumar Bammrotwar
NA
1
1.6k
Problem in connection with mysql
May 2 2012 1:20 PM
hi I'm getting problem in the connection with mysql
this is my coding in a class can anyone please tell me how to open the connection.
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using MySql.Data.MySqlClient;
namespace library_management_system
{
class Class1
{
}
public class database1
{
public string cnn = "server=127.0.0.1;user=root;database=library management system;port=3306;password=password;";
public string cmd;
public string da;
public string dr;
}
public class conn
{
database1 x = new database1();
MySqlConnection cnn1 = new MySqlConnection(cnn1.ConnectionString = x.cnn );
cnn1 .open();
MySqlCommand cmd = new MySqlCommand(x.cmd, cnn1);
}
}
Reply
Answers (
1
)
Discovering controls beneath a programmatically drawn rectangle
Using Date and Time