Re: ATL Service & InitializeSecurity
From: Alexander Nickolov (agnickolov_at_mvps.org)
Date: 09/20/04
- Next message: Todd J. Barlow: "Windows XP Sp2 Breaks AtlAdvise () calls?"
- Previous message: edsonw: "RE: Why do I get LNK2001 unresolved _main symbol error with this code"
- In reply to: khalprin: "Re: ATL Service & InitializeSecurity"
- Next in thread: khalprin: "Re: ATL Service & InitializeSecurity"
- Reply: khalprin: "Re: ATL Service & InitializeSecurity"
- Messages sorted by: [ date ] [ thread ]
Date: Mon, 20 Sep 2004 15:32:13 -0700
Yes, service startup problems are notoriously hard to debug...
Insert code to log (into a file for example) checkpoints in the
service startup code to see how far you progress. This should
help you narrow down where you get stuck. You can then
post that piece of code and we can pore over it in the group.
BTW, if your service does not start whatsoever for a COM
client, you have a COM registration problem.
-- ===================================== Alexander Nickolov Microsoft MVP [VC], MCSD email: agnickolov@mvps.org MVP VC FAQ: http://www.mvps.org/vcfaq ===================================== "khalprin" <khalprin@discussions.microsoft.com> wrote in message news:8C281129-A1ED-4CE7-85C2-7DB28F5B931D@microsoft.com... > Yes, it does start when I start it from the services applet. However... > > When registered as a service, a client cannot start it when calling > CoCreateInstance() to get an interface from it. > > When registered as a local server, a client can start it when calling > CoCreateInstance() to get an interface from it. > > > "Alexander Nickolov" wrote: > >> Does your service start? Can you start it successfully from the >> services applet? CoInitializeSecurity doesn't seem to be relevant >> to your problem. >> >> -- >> ===================================== >> Alexander Nickolov >> Microsoft MVP [VC], MCSD >> email: agnickolov@mvps.org >> MVP VC FAQ: http://www.mvps.org/vcfaq >> ===================================== >> >> "khalprin" <khalprin@discussions.microsoft.com> wrote in message >> news:1E5CB341-EC4B-4AB2-8F6D-6A334CBCDAA9@microsoft.com... >> > This is giving me fits... I'm using Visual Studio .NET 2003. I've >> > created >> > a >> > non-attributed service with one interface exposed. I can use >> > CoCreateInstance() from a client and call the interface when the ATL >> > service >> > is registered as a local server instead of a service. When the ATL >> > service >> > is registered as a service, the client's CoCreateInstance() returns >> > 'server >> > execution failed'. I've tried this with the default >> > InitializeSecurity() >> > in >> > the ATL service - which does nothing. And I've tried it by calling >> > CoInitializeSecurity() in the IntializeSercurity() method with a null >> > descriptor. The dcom settings look right - the service is registered >> > in >> > the >> > local system account and 'Everyone' has launch and access permissions. >> > What >> > am I missing? >> > >> >> >>
- Next message: Todd J. Barlow: "Windows XP Sp2 Breaks AtlAdvise () calls?"
- Previous message: edsonw: "RE: Why do I get LNK2001 unresolved _main symbol error with this code"
- In reply to: khalprin: "Re: ATL Service & InitializeSecurity"
- Next in thread: khalprin: "Re: ATL Service & InitializeSecurity"
- Reply: khalprin: "Re: ATL Service & InitializeSecurity"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|