Unable to use ADO in Delphi 7 Apache 2.x Web Service


2005-07-28 05:11:42 AM
delphi222
Using Delphi 7, I have created an Apache 2.x Web Service DLL whose
purpose is to deliver certain data items, in XML, to a web app written in
Java. The web service compiles fine and successfully transmits XML data
to the Java app as long as the data is hard coded. But when the web
service attempts to first get the data from MS SQL Server, using Delphi 7 ADO
Connection and Query objects (placed in the SOAP Web Module), it
generates the following Memory Access SOAP Fault error when run in the
Java web app:
"Access violation at address 0088AAA7 in module 'ADETest.dll'. Read of address
000000AC"
We thought we had the problem nailed when we found out that we must explicitly
run
CoInitializeEx(nil,COINIT_MULTITHREADED)
from a ComInit unit listed as the first item in the uses clause of the .dpr
unit (to initialize the COM objects in the ActiveX Unit); but the error
continues to arise as soon as the code tries to get the data.
I am new to Web Services and XML, so may well not be understanding something
that has to be done. Any assistance would be much appreciated.
Roland Peters, IS Programmer.