Hallo,
i have install dbxmda400.exe and my problem is that if i want to connect to mysql server with the ip 192.168.1.200 that my application want to conect to localhost with ip 192.168.1.185.
Where is the problem?
How i can conect to a mysql server?
thx.
Borland C++ 2006 dbexpress connection Problem?
In the code below replace values of the Database, User_Name and Password parameters with settings of your MySQL, and execute this code in your application.
Code: Select all
#include
...
TSQLConnection* SQLConnection1 = new TSQLConnection(Application);
SQLConnection1->DriverName = "MySQL Direct by Core Lab";
SQLConnection1->LibraryName = "dbexpmda30.dll";
SQLConnection1->VendorLib = "1";
SQLConnection1->GetDriverFunc = "getSQLDriverMySQLDirect";
SQLConnection1->Params->Clear();
SQLConnection1->Params->Add("DriverName=MySQL");
SQLConnection1->Params->Add("HostName=192.168.1.200");
SQLConnection1->Params->Add("Database=test");
SQLConnection1->Params->Add("User_Name=root");
SQLConnection1->Params->Add("Password=root");
SQLConnection1->Open();
ShowMessage(BoolToStr(SQLConnection1->Connected, True));