RE: DCOMCNFG nightmare with service
- From: markiemooster <markiemooster@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Fri, 3 Oct 2008 07:48:06 -0700
Phew! Found the problem at last. Not the DCOMCNFG settings after all...
I added this line:
val AppID = s '%APPID%'
to the ForceRemove section to my COM object's .rgs file. So now it looks
like this (CLSID/GUIDS removed for clarity):
HKCR
{
ImageExtractorService.ImageExtractor.1 = s 'ImageExtractor Class'
{
CLSID = s '{....}'
}
ImageExtractorService.ImageExtractor = s 'ImageExtractor Class'
{
CLSID = s '{....}'
CurVer = s 'ImageExtractorService.ImageExtractor.1'
}
NoRemove CLSID
{
ForceRemove {....} = s 'ImageExtractor Class'
{
ProgID = s 'ImageExtractorService.ImageExtractor.1'
VersionIndependentProgID = s 'ImageExtractorService.ImageExtractor'
ForceRemove 'Programmable'
LocalServer32 = s '%MODULE%'
val AppID = s '%APPID%'
'TypeLib' = s '{----}'
}
}
}
I presume this registry setting associates my COM object to my service in
some way and allows DCOM to proceed normally.
Hey, I only wasted two soul-destroying days on this, I suppose it could've
been worse!
Thanks everyone.
"markiemooster" wrote:
I've written an ATL service and added an ATL simple object using VS2008. If.
I pass /RegServer to the service on the command line (making it operate as a
standard .EXE), and run my test app all is fine. However, if I unregister it
(/UnregServer), and then pass /Service to the service on the command line
(making it operate as a real service), in my test app CoCreateInstance fails
with CO_E_SERVER_EXEC_FAILURE (0x80080005) after 30 seconds or so.
I've looked in task manager, and if the service is already started, another
copy of the process appears briefly and vanishes.
I've read lots of advice about using DCOMCNFG to configure the service but
nothing has seemed to work so far. I wasted most of the day yesterday
tinkering with settings and getting more and more frustrated. Surely this
was supposed to be easy, right?
Currently my service is set to log on using an Administrator account. When
I open DCOMCNFG I see two entries related to my service: ImageExtractor Class
(the interace of my ATL simple object) and ImageExtractorService (my service).
I've set both of them to run using the same Administrator account identity.
In terms of security settings, both ImageExtractor Class and
ImageExtractorService are configured identically:
Launch and Activation Permissions: Administrators have all permissions
Access Permissions: Administrators have all permissions
Configuration Permissions: Administrators have all permissions
I've checked and DCOM is enabled on my computer.
I've added the Administrator account I use to the "Distributed COM Users"
group
Under "My Computer" in DCOM:
Access Permissions -
Edit Limits: Distributed DCOM Users have all permissions
Launch and Activation Permissions -
Edit Limits: Distributed DCOM Users have all permissions
In case it makes any difference, I'm running Vista Ulitmate with SP1.
I'm tearing my hair out here. Could someone please tell me what I'm missing?
Thanks.
- References:
- DCOMCNFG nightmare with service
- From: markiemooster
- DCOMCNFG nightmare with service
- Prev by Date: Re: registration order of tlb, proxy/stub, exe
- Next by Date: Re: DCOMCNFG nightmare with service
- Previous by thread: Re: DCOMCNFG nightmare with service
- Next by thread: Making HTTPS call from a BHO
- Index(es):
Relevant Pages
|