关于改动ODBC配置的问题
//---------------------------------------------------------------------------
#include <vcl.h>
#pragma hdrstop
#include "UnitODBC.h"
#include "odbcinst.h"
//---------------------------------------------------------------------------
#pragma package(smart_init)
#pragma resource "*.dfm"
TFormODBC *FormODBC;
//---------------------------------------------------------------------------
__fastcall TFormODBC::TFormODBC(TComponent* Owner)
: TForm(Owner)
{
}
//---------------------------------------------------------------------------
void __fastcall TFormODBC::ButtonLocalhostClick(TObject *Sender)
{
SQLConfigDataSource(this,ODBC_CONFIG_SYS_DSN,"MySQL ODBC 5.1 Driver","DSN=localization\Server=localhost");
}
//---------------------------------------------------------------------------
代码如上,想点击ButtonLocalhost按钮之后将名为localization的System DSN的server改为localhost,但是我运行之后报错如下:
[ILINK32 Error] Error: Unresolved external 'SQLConfigDataSource' referenced from C:\DOCUMENTS AND SETTINGS\GENE XIE\DESKTOP\MY WORK\LOCALIZATION\RESEARCH_EVN\DEBUG\UNITODBC.OBJ
请大家帮忙看看出什么问题了,要怎么处理,谢谢!