Solved

Cannot unregister a DLL.

Posted on 2006-07-04
3
286 Views
Last Modified: 2013-12-04
I am using the Java ActiveX Bridge which creates and registers a DLL for use in VBA.  Not knowing the the Java Packager was registering the DLL I used REGSVR32 to register the DLL again which created multiple copies of it.  I've tried using REGSVR32 /u and it tells me that it unregisters it.  But I can't seem to get rid of those orphaned instances.  When I try to add the Components in VB6 it tells me they are invalid.  Do I have to alter the registry manually and if so, can you point me in the right direction as to which ones to access?

Thanks
0
Comment
Question by:techhound
  • 2
3 Comments
 
LVL 86

Expert Comment

by:jkr
Comment Utility
Altering the registry does not have any effect on instances that are already running, it just means that new instances of that COM object can't be created anymore. You'll have to close/terminate all other processes that are using this class.
0
 
LVL 5

Accepted Solution

by:
bastibartel earned 500 total points
Comment Utility
Set this value to 1 (only on Windows NT 4.0 - I believe):
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\explorer\AlwaysUnloadDll

Get ProcessExplorer
http://www.multiware-distribution.ch/produkte/Northern/PrExplorer.htm
and locate the executable(s) using the dll and kill them

or
try and start in safe mode and remove the dll.


Cheers,
Sebastian
0
 
LVL 86

Expert Comment

by:jkr
Comment Utility
Funny, "AlwaysUnloadDll" is not supported on W2k, XP and later: http://msdn.microsoft.com/library/en-us/shellcc/platform/shell/programmersguide/shell_basics/shell_basics_programming/debugging.asp ("Debugging with the Shell"):

"The Shell automatically unloads a DLL when its usage count is zero, but only after the DLL has not been used for a period of time. This inactive period might be unacceptably long at times, especially when a Shell extension DLL is being debugged. For operating systems *prior* to Windows 2000, you can shorten the inactive period by adding the following information to the registry. [...]"
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

This article describes how to add a user-defined command button to the Windows 7 Explorer toolbar.  In the previous article (http://www.experts-exchange.com/A_2172.html), we saw how to put the Delete button back there where it belongs.  "Delete" is …
If you have ever found yourself doing a repetitive action with the mouse and keyboard, and if you have even a little programming experience, there is a good chance that you can use a text editor to whip together a sort of macro to automate the proce…
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…

743 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

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now