RegSvr32 exit codes [modified]
-
I've got a shell extension dll that can't be registered - regsvr32 fails with exit code 0x3 (this happens on a 64-bit Vista), but I can't understand what the exit code means. Does anyone know what might be the problem and what this exit code means? And this problem doesn't happen in XP 32-bit (my development machine).
There is sufficient light for those who desire to see, and there is sufficient darkness for those of a contrary disposition. Blaise Pascal
modified on Monday, August 18, 2008 1:31 PM
-
I've got a shell extension dll that can't be registered - regsvr32 fails with exit code 0x3 (this happens on a 64-bit Vista), but I can't understand what the exit code means. Does anyone know what might be the problem and what this exit code means? And this problem doesn't happen in XP 32-bit (my development machine).
There is sufficient light for those who desire to see, and there is sufficient darkness for those of a contrary disposition. Blaise Pascal
modified on Monday, August 18, 2008 1:31 PM
Do you have a
DllRegisterServer()
function?"Love people and use things, not love things and use people." - Unknown
"The brick walls are there for a reason...to stop the people who don't want it badly enough." - Randy Pausch
-
Do you have a
DllRegisterServer()
function?"Love people and use things, not love things and use people." - Unknown
"The brick walls are there for a reason...to stop the people who don't want it badly enough." - Randy Pausch
Yes, it is a ATL/COM shell extension, with MFC support enabled. It was done by following this article from codeproject - http://www.codeproject.com/KB/shell/shellextguideindex.aspx[^] I forgot to mention that the problem *doesn't* happen in XP 32-bit (my development machine).
There is sufficient light for those who desire to see, and there is sufficient darkness for those of a contrary disposition. Blaise Pascal
-
Yes, it is a ATL/COM shell extension, with MFC support enabled. It was done by following this article from codeproject - http://www.codeproject.com/KB/shell/shellextguideindex.aspx[^] I forgot to mention that the problem *doesn't* happen in XP 32-bit (my development machine).
There is sufficient light for those who desire to see, and there is sufficient darkness for those of a contrary disposition. Blaise Pascal
sashoalm wrote:
Yes...
And what does it return?
"Love people and use things, not love things and use people." - Unknown
"The brick walls are there for a reason...to stop the people who don't want it badly enough." - Randy Pausch
-
I've got a shell extension dll that can't be registered - regsvr32 fails with exit code 0x3 (this happens on a 64-bit Vista), but I can't understand what the exit code means. Does anyone know what might be the problem and what this exit code means? And this problem doesn't happen in XP 32-bit (my development machine).
There is sufficient light for those who desire to see, and there is sufficient darkness for those of a contrary disposition. Blaise Pascal
modified on Monday, August 18, 2008 1:31 PM
-
sashoalm wrote:
Yes...
And what does it return?
"Love people and use things, not love things and use people." - Unknown
"The brick walls are there for a reason...to stop the people who don't want it badly enough." - Randy Pausch
DllRegisterServer is just boilerplate code put by AppWizard, and it returns _Module.RegisterServer(TRUE). Btw, I also have a *.rgs file. Could something be wrong there?
/////////////////////////////////////////////////////////////////////////////
// DllRegisterServer - Adds entries to the system registrySTDAPI DllRegisterServer(void)
{
// registers object, typelib and all interfaces in typelib
return _Module.RegisterServer(TRUE);
}Actually the entire file is boilerplate, I haven't changed a line of code there I think. Here's the code:
// ExplorerExt.cpp : Implementation of DLL Exports.
// Note: Proxy/Stub Information
// To build a separate proxy/stub DLL,
// run nmake -f ExplorerExtps.mk in the project directory.#include "stdafx.h"
#include "resource.h"
#include
#include "ExplorerExt.h"#include "ExplorerExt_i.c"
#include "ExplExt.h"CComModule _Module;
BEGIN_OBJECT_MAP(ObjectMap)
OBJECT_ENTRY(CLSID_ExplExt, CExplExt)
END_OBJECT_MAP()class CExplorerExtApp : public CWinApp
{
public:// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CExplorerExtApp)
public:
virtual BOOL InitInstance();
virtual int ExitInstance();
//}}AFX_VIRTUAL//{{AFX\_MSG(CExplorerExtApp) // NOTE - the ClassWizard will add and remove member functions here. // DO NOT EDIT what you see in these blocks of generated code ! //}}AFX\_MSG DECLARE\_MESSAGE\_MAP()
};
BEGIN_MESSAGE_MAP(CExplorerExtApp, CWinApp)
//{{AFX_MSG_MAP(CExplorerExtApp)
// NOTE - the ClassWizard will add and remove mapping macros here.
// DO NOT EDIT what you see in these blocks of generated code!
//}}AFX_MSG_MAP
END_MESSAGE_MAP()CExplorerExtApp theApp;
BOOL CExplorerExtApp::InitInstance()
{
_Module.Init(ObjectMap, m_hInstance, &LIBID_EXPLOREREXTLib);
return CWinApp::InitInstance();
}int CExplorerExtApp::ExitInstance()
{
_Module.Term();
return CWinApp::ExitInstance();
}/////////////////////////////////////////////////////////////////////////////
// Used to determine whether the DLL can be unloaded by OLESTDAPI DllCanUnloadNow(void)
{
AFX_MANAGE_STATE(AfxGetStaticModuleState());
return (AfxDllCanUnloadNow()==S_OK && _Module.GetLockCount()==0) ? S_OK : S_FALSE;
}/////////////////////////////////////////////////////////////////////////////
// Returns a class factory to create an object of the requested typeSTDAPI DllGetClassObject(REFCLS
-
thanks for the advice, I checked it, and there was one warning, and two files had red icons to the left.
Warning: At least one module has an unresolved import due to a missing export function in a delay-load dependent module. c:\windows\system32\SHLWAPI.DLL c:\windows\system32\IEFRAME.DLL
btw at first i had checked it with 32-bit version of depends, and it gave different results even though it managed to launch on the 64-bit Vista. :confused:There is sufficient light for those who desire to see, and there is sufficient darkness for those of a contrary disposition. Blaise Pascal
-
thanks for the advice, I checked it, and there was one warning, and two files had red icons to the left.
Warning: At least one module has an unresolved import due to a missing export function in a delay-load dependent module. c:\windows\system32\SHLWAPI.DLL c:\windows\system32\IEFRAME.DLL
btw at first i had checked it with 32-bit version of depends, and it gave different results even though it managed to launch on the 64-bit Vista. :confused:There is sufficient light for those who desire to see, and there is sufficient darkness for those of a contrary disposition. Blaise Pascal
-
Take a look here. http://www.dependencywalker.com/faq.html[^] Specifically Can Dependency Walker help me figure out why my component won't register?