程序出错,真郁闷
//参数查询
TADOQuery* objQuery =new TADOQuery(NULL);
try
{
objQuery->Connection=myConn;
objQuery->SQL->Add(strSQL);
objQuery->Open();
objQuery->Active=true;
TMemoField* mf;
//新增记录
objQuery->Append();
mf=(TMemoField*)objQuery->FieldByName(strTextField);
mf->Assign(Content);
objQuery->Post();
objQuery->Close();
delete objQuery;//////一运行到这里就出错 'EAccessViolation'的错误
}
catch(EADOError *err)
{
delete objQuery;
throw Exception(err->Message);
}