I want to write an NT Service that uses the TOutlookApplication server (Delphi 6), to watch for incoming emails.
I wrote a simple test app that hooks the NewMail event, and that worked fine.
No when I tried to convert this to an NT Service I get an error when trying to connect.
The error message was ...
"Service failed on execute: CoInitialize has not been called."
I found a reference that suggested manually calling CoInitialize, but this has just changed the error...
"Service failed on execute: Server execution failed."
Is there a limitation which prevents me from doing what I want to do?
Can you suggest an alternative?