Re: ADO Based Datamodules in ISAPI applications

From: Brian Bushay TeamB (BBushay_at_Nmpls.com)
Date: 07/01/04


Date: Thu, 01 Jul 2004 12:54:22 -0500


>I have an application that uses a Datamodule with ADO components on it.
>I would like to put an ISAPI (TWebModule) around this datamodule but having problems (basically the web server crashes). I think the problem is the use of ADO com components.
>I have succeeded in using ADO in an ISAPI application that doesn't have seperate datamodules, using the ActiveX call coinitialize(nil),but, this doesn't seem to help with with my scenario of a seperate datamodule. I have tried putting coinitialse on the create event of both the TWebModule and the datamodule.

An Isapi DLL calls CoInitialize in its Applicaiton.initialize line of code.
Since each dll created has its own thread you should not have to call
Coiitialize.
How are you creating the data module?
You should be doing it from the WebModule

MyDataModule := TmyDataModule.create(nil)
Once it is created open its TadoConnection and any components.

--
Brian Bushay (TeamB)
Bbushay@NMPLS.com


Relevant Pages

  • Re: Corrupt DataModule?
    ... I did not put visual controls in the data module. ... > controls in DataModule or yours test not apply to the problem, ... >> So either the problem is in the number of ADO components that are in one ...
    (borland.public.delphi.database.ado)
  • open/close procedures
    ... I have an application that I'm adding some ADO components to and with the ... components on a datamodule I have errors closing the application. ... too many cosecutive exceptions' blah blah blah. ...
    (borland.public.delphi.database.ado)
  • ADO Based Datamodules in ISAPI applications
    ... I have an application that uses a Datamodule with ADO components on it. ... I would like to put an ISAPI (TWebModule) around this datamodule but having problems. ...
    (borland.public.delphi.database.ado)
  • Re: Corrupt DataModule?
    ... You were referring that Visual Controls are not reflecting properly changes ... in DataModule or yours test not apply to the problem, ... > decided to copy all the tables and queries to the new data module. ... > So either the problem is in the number of ADO components that are in one ...
    (borland.public.delphi.database.ado)
  • Re: ADO + CoInitialize in threads? Mystery...
    ... Bas van Beek wrote: ... > drop ADO Components on a form or datamodule and use those objects in ... :-) This is a DataModule with at least one ... Cell: +46 733 442464 ...
    (borland.public.delphi.database.ado)