Solved

VC++ dll is not regsvr32-ing

Posted on 2000-05-15
9
377 Views
Last Modified: 2008-03-17
My VC++ activeX dll is not regsvr32-ing successfully on my user machine.  It works ok on my development machine.  Maybe the user is missing some file that the mfc library update supplies?  Unlikely, since my user has Win98 SE.  

I am getting a loadlibrary failed 0x0000485 - but then if he tries to regsvr32 XXXjunknonexistentAnyText  he gets the same message!! :-(   He is however browsing and typing the correct path.

At first I gave him a debug version and thought that since he didn't have the mfc*d.dll's (notice the 'd') - then that was the reason it wasn't working.  Now that I've given him a production version dll, it hasn't helped :-(
0
Comment
Question by:abulka
  • 5
  • 2
  • 2
9 Comments
 
LVL 3

Expert Comment

by:mnewton022700
ID: 2813272
It most likely that his version of MFC42.dll is not as uptodate as yours. Compare the version on his computer with the version on your computer.

My advice would be to use the MSDEV tool "Depends" to see all the dependent DLLs of your ActiveX Dll. Then make sure that your user has uptodate versions of all these DLLs.

Most install programs will help you do this.

Doesn't regsvr32 just have the best error messages :)
0
 

Author Comment

by:abulka
ID: 2813440
Yeah - I love the regsvr32 error messages ;-) - and the way it doesn't distinguish between a missing dll and a dll that it depends on being missing etc.  Who knows what's missing, in the end...

Scanning my custom VC++ dll, it seems that the missing dll was MSVCP60.dll, but when this was added to c:\windows\system the message changed into:
  Loadlibrary failed, getlasterror
  error code 0x0000001f.

which I consider is progress. :-)  I am downloading the mfc patch now to see if it helps...

Running the mfcinst.exe updated something but the regsvr32 command still fails :-(

I'm sure I have all the 1st level dlls that are referred to by my custom activeX dll.  

MFC42.DLL
MSVCRT.dll
KERNEL32.dll
USER32.dll
GDI32.dll
OLEAUT32.dll
MSVCP60.dll

but whether they are upto date and what THEY refer to is another matter.  I would have thought that running the mfcinst.exe patch would have fixed things.  I'm running out of ideas.  I've even tried running different versions I found of regsvr32 on my 98 machine...
 
0
 
LVL 4

Accepted Solution

by:
AssafLavie earned 60 total points
ID: 2814548
Hi.
This is probably because you compiled you DLL in a Min-Size build. When you do that, ATL, by default, links to the Registrar dynamicaly and than you have to ship the ATL.dll along with you product.
The solution is to build with Min-Dependencies or just add _ATL_STATIC_REGISTRY to your projects definitions.

The registrar in case you're wondering is the MS component that lets you use RGS files, and if you link to it statically - it only adds 8KB to your file.

Hope this is indeed the answer - it usualy is to this type of problem.
0
Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

 
LVL 3

Expert Comment

by:mnewton022700
ID: 2815276
Hi Andy,

Are you able to register the GET control and TSS default view factory on the 98 machine?

Try copying the file msvcirt.dll from your machine to the 98 machine into the directory that contains your DLL.

You can email me at mnewton@tomsawyer.com if you would like to speed up this discussion.

Mike.

--
Mike Newton
Tom Sawyer Software


ps.
Sorry Assaf, I've got inside information on this one, it's not ATL. :)
0
 

Author Comment

by:abulka
ID: 2815489
> Are you able to register the GET control and TSS default view factory on the 98 machine?

Not sure what the GET control means, but the default views work ok on the user machine.  As per your suggestion

> Try copying the file msvcirt.dll from your machine to the 98 machine into the directory that contains your DLL.
<<

We put
     msvcirt.dll  - version 6.00.8168.0 or later
into the ts/...../bin  (although we also had it in the windows/system folder too - same version) and it didn't help, I'm afraid.

-Andy
0
 

Author Comment

by:abulka
ID: 2815961
You said:

If this latest effort doesn't happen to fix the problem
have your user download a dependency walker from:

http://msdn.microsoft.com/library/techart/samples/5289.exe


>Dependency walker found it!   We determined that msvcp60.dll was
>corrupt/missing, so I sent him another version of msvcp60.dll and that
>allowed ts3.dll to register!  :-) :-) :-)
0
 

Author Comment

by:abulka
ID: 2815965
oops - I meant for mnewton to have the points
0
 
LVL 4

Expert Comment

by:AssafLavie
ID: 2823109
How many points were there? 60?
I'll post a question so MNewton ca collect the points.
ok?
0
 

Author Comment

by:abulka
ID: 2823992
Thanks that nice of you.  I've already emailed MNewton apologising, so as to the points - that's between MNewton and yourself.  Sorry for mucking you about.
-A
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
SetCurrentDirectory path limit 7 131
c++ reading data from file into two dimensional array 3 117
designing in object programming 12 94
Indy 10 not Receiving UDP broadcast 3 22
What is C++ STL?: STL stands for Standard Template Library and is a part of standard C++ libraries. It contains many useful data structures (containers) and algorithms, which can spare you a lot of the time. Today we will look at the STL Vector. …
Container Orchestration platforms empower organizations to scale their apps at an exceptional rate. This is the reason numerous innovation-driven companies are moving apps to an appropriated datacenter wide platform that empowers them to scale at a …
The viewer will learn how to use the return statement in functions in C++. The video will also teach the user how to pass data to a function and have the function return data back for further processing.
The viewer will be introduced to the technique of using vectors in C++. The video will cover how to define a vector, store values in the vector and retrieve data from the values stored in the vector.

808 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question