Hi,
I'm developing a web server (ISAPI) application in C++Builder 2007 using the latest dbExpress drivers. The app complies fine but when the statement TCRSQLConnection->Connected = true is executed, it generates an EAccessViolation message (the same happens using Borland's version of the drivers). I have used identical code in a standard desktop application and it works fine.
Any thoughts??
Regards,
Chris
EAccessViolation message from Web Server dll
We could not reproduce the problem.
Please send me a complete small sample at dbxsda*crlab*com to demonstrate it, including script to create server objects if it is necessary.
Also supply me the following information:
- exact version of DbxSda;
- exact version of your IDE (including installed update packs);
- exact version of SQL Server.
Please send me a complete small sample at dbxsda*crlab*com to demonstrate it, including script to create server objects if it is necessary.
Also supply me the following information:
- exact version of DbxSda;
- exact version of your IDE (including installed update packs);
- exact version of SQL Server.
Hello Chris,
though the connection will be used in a separate thread you have to initialize ole:
Without this initialization the connect will raise an exception.
I derived a derivation of TSQLConnection performing this initialization automatically in DoConnect method:
Hope this helps.
Michael
though the connection will be used in a separate thread you have to initialize ole:
Code: Select all
CoInitialize(nil);
MyConnection.Connected := true;
I derived a derivation of TSQLConnection performing this initialization automatically in DoConnect method:
Code: Select all
procedure TktDBConnection.DoConnect;
begin
try
CoInitialize(nil);
except
// we do not want any exceptions here
end;
inherited;
// retrieve internal database informations here
end;
Michael