Hi, I have been searching thru the net for the past 4 days and i am stuck at this problem badly so i hope anyone here can help me =(. Extremely new to mysql.
I am currently using VC++ for this I am trying to connect to mysql and i am unable to connect it.
System::Void SelectTable()
{
ADODB::Recordset ^ rst;
rst = gcnew ADODB::Recordset();
conADO = gcnew ADODB::Connection();
System:

ata:

qlClient:

qlConnection ^ConnectDatabase = gcnew System:

ata:

qlClient:

qlConnection(L"Server =localhost;"
L"Database=Data\\Database.mdb;"
L"Persist Security Info=true;"
L"User ID='root';"
L"Password='123456'" );
try
{
ConnectDatabase->Open();
System::Console::WriteLine(" File opened");
}
catch(System::Exception ^e)
{
System::Console::WriteLine("Error : " + e->ToString());
}
}
I think i am doing something wrong with connection part. I tired with changing the "server" part in the connection to Server = 127.0.0.1 and it still don't work.
i have the mysql server when trying to connect to it.
Error : System.Data.SqlClient.SqlExpection: An error has occurred while establishing the connection to the server. When connecting to SQL Server 2005 , This failure may be caused by the fact under the default settings SQL server does not allow remote connections. ( provider : Named Pipes Provider, error: 40 - Could not open Connection to Sql server )
Anyone Can help guide me through this? Been searching thru the net all i get are mainly php examples.