rxgmoral 0 Newbie Poster

about VC+MySQL problem:)
i install mysql odbc V5.0 driver
i need to ADO Connect MYSQL DB;
code:
_ConnectionPtr m_CMConnect;
::CoInitialize(NULL);
m_CMConnect.CreateInstance(__uuidof(Connection));
m_CMConnect->Open("Provider=MySQL;server=localhost;DataBase=test;port=3306;uid=root;pwd=","","",-1);

but Program run error.....
how to Ado Connect MYSQL DB;
thank:)

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.