Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. RegSvr32 exit codes [modified]

RegSvr32 exit codes [modified]

Scheduled Pinned Locked Moved C / C++ / MFC
delphilinuxhelpquestion
9 Posts 4 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    sashoalm
    wrote on last edited by
    #1

    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

    D S 2 Replies Last reply
    0
    • S sashoalm

      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

      D Offline
      D Offline
      David Crow
      wrote on last edited by
      #2

      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

      S 1 Reply Last reply
      0
      • D David Crow

        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

        S Offline
        S Offline
        sashoalm
        wrote on last edited by
        #3

        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

        D 1 Reply Last reply
        0
        • S sashoalm

          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

          D Offline
          D Offline
          David Crow
          wrote on last edited by
          #4

          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

          S 1 Reply Last reply
          0
          • S sashoalm

            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

            S Offline
            S Offline
            Stephen Hewitt
            wrote on last edited by
            #5

            Perhaps some required runtime DLL is missing. Use Depends[^] (or some other tool that does something similar) to see if this is the case.

            Steve

            S 1 Reply Last reply
            0
            • D David Crow

              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

              S Offline
              S Offline
              sashoalm
              wrote on last edited by
              #6

              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 registry

              STDAPI 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 OLE

              STDAPI 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 type

              STDAPI DllGetClassObject(REFCLS

              1 Reply Last reply
              0
              • S Stephen Hewitt

                Perhaps some required runtime DLL is missing. Use Depends[^] (or some other tool that does something similar) to see if this is the case.

                Steve

                S Offline
                S Offline
                sashoalm
                wrote on last edited by
                #7

                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

                D 1 Reply Last reply
                0
                • S sashoalm

                  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

                  D Offline
                  D Offline
                  Dan 0
                  wrote on last edited by
                  #8

                  Take a look here. http://www.dependencywalker.com/faq.html[^] Specifically Can Dependency Walker help me figure out why my component won't register?

                  S 1 Reply Last reply
                  0
                  • D Dan 0

                    Take a look here. http://www.dependencywalker.com/faq.html[^] Specifically Can Dependency Walker help me figure out why my component won't register?

                    S Offline
                    S Offline
                    sashoalm
                    wrote on last edited by
                    #9

                    Thanks, I fixed the problem

                    There is sufficient light for those who desire to see, and there is sufficient darkness for those of a contrary disposition. Blaise Pascal

                    1 Reply Last reply
                    0
                    Reply
                    • Reply as topic
                    Log in to reply
                    • Oldest to Newest
                    • Newest to Oldest
                    • Most Votes


                    • Login

                    • Don't have an account? Register

                    • Login or register to search.
                    • First post
                      Last post
                    0
                    • Categories
                    • Recent
                    • Tags
                    • Popular
                    • World
                    • Users
                    • Groups