Not able to register a C++ service
-
Hi all, I have made a .net application which usees a COM component hosted by a C++ service. The service is a simple C++ service developed using ATL (and not using MFC). My development environment is Windows XP. Now everything works fine on my dev machine. But when I tried to install my service on a fresh VISTA machine, I could not do so. I got below message: Activation context generation failed for "C:\Windows\System32\PSPW.exe". Dependent Assembly Microsoft.VC90.DebugCRT,processorArchitecture="x86",publicKeyToken="1fc8b3b9a1e18e3b",type="win32",version="9.0.21022.8" could not be found. Please use sxstrace.exe for detailed diagnosis. But when I tried to install my service on VISTA machine which already have Visual Studio 2008, service got installed without any problem. It means before installing my service on a fresh VISTA (or even fresh Windows 7), I also need to install/copy some other dlls which comes with VS 2008. Can anybody help me in knowing how should I go about it. Or might be my assumption that I need to install/copy some other VS dlls is wrong. I could not resolve this problem. So seeking for help. Regards Aseem
modified on Sunday, October 10, 2010 11:36 PM
-
Hi all, I have made a .net application which usees a COM component hosted by a C++ service. The service is a simple C++ service developed using ATL (and not using MFC). My development environment is Windows XP. Now everything works fine on my dev machine. But when I tried to install my service on a fresh VISTA machine, I could not do so. I got below message: Activation context generation failed for "C:\Windows\System32\PSPW.exe". Dependent Assembly Microsoft.VC90.DebugCRT,processorArchitecture="x86",publicKeyToken="1fc8b3b9a1e18e3b",type="win32",version="9.0.21022.8" could not be found. Please use sxstrace.exe for detailed diagnosis. But when I tried to install my service on VISTA machine which already have Visual Studio 2008, service got installed without any problem. It means before installing my service on a fresh VISTA (or even fresh Windows 7), I also need to install/copy some other dlls which comes with VS 2008. Can anybody help me in knowing how should I go about it. Or might be my assumption that I need to install/copy some other VS dlls is wrong. I could not resolve this problem. So seeking for help. Regards Aseem
modified on Sunday, October 10, 2010 11:36 PM
First of all try building a release version. Then when you've done that distribute the "Microsoft Visual C++ 2008 redistributable" (name from memory, might have it slightly wrong) with your service. Either add it to the installation media OR set the installer to download it directly from MS on installation. Personally I bung it on the CD. Cheers, Ash
-
First of all try building a release version. Then when you've done that distribute the "Microsoft Visual C++ 2008 redistributable" (name from memory, might have it slightly wrong) with your service. Either add it to the installation media OR set the installer to download it directly from MS on installation. Personally I bung it on the CD. Cheers, Ash
Hi Ash, Thanks for your reply. I could fix the problem the way you said. Thanks and Regards Aseem Sharma