Solved

How to remove a component from VB6

Posted on 2004-08-18
7
297 Views
Last Modified: 2008-01-16
How does one remove a component from the component list in VB6? We don't want to use it again, ever.

I'm not very proficient at VB, so this is a newbie question.

A customer installed a demo component into their VB6 development environment while logged in as USERA.
The machine, a WinXP Pro box, had been part of a workgroup when this was installed.  The workstation joined a domain, which created a new profile for the user(USERB).  We have tried to migrate the profile from USERA to USERB.

When USERB starts up VB, they get prompted for the installation CD from the demo.  They can cancel through the questions/prompts, but its annoying.   When USERA starts up VB, they get no prompts for installation.  We're trying to uninstall the demo component all together, but don't have the demo CD, its not listed in the "Add/Remove Programs" list, and we don't find any "un-install" menu item.  

I surmise that the component's install didn't install the component with "All Users" security; instead it must have installed it only for the current user (which was USERA, at the time).    We can delete directories and the .OCX files, but I'd like to get it removed from their component list completely, regardless of user.

0
Comment
Question by:studios
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
7 Comments
 
LVL 7

Expert Comment

by:Burbble
ID: 11832296
I'm not positive on this, but you can try unregistering the component:

Start > Run :

regsvr32 /u FILENAME.OCX

I will look into this further and get back to you if I find anything.

-Burbble
0
 
LVL 7

Accepted Solution

by:
Burbble earned 250 total points
ID: 11832350
Yep, that does it. If it's not located in the WINDOWS\SYSTEM directory, you will have to type the full path surrounded by quotes:

regsvr32 /u "C:\Program Files\Application\MyActiveXControl.OCX"

You can also set it so no "DLL Unregister Succeed" message box is shown like this:

regsvr32 /u /s "C:\Program Files\Application\MyActiveXControl.OCX"

(/s is for "silent")

-Burbble
0
 
LVL 2

Expert Comment

by:kouroshparsa
ID: 11862605
Try "\windows\system32\MyActiveXControl.OCX"
0
 
LVL 7

Expert Comment

by:Burbble
ID: 11864225
If it is located in the WINDOWS\SYSTEM directory (or equivilent), you can use:

regsvr32 /u MyActiveXControl.ocx

like I said before...

If you are coding this into your program (using Shell, for instance), then it is better to call it with the full path, just in case.

(Full path meaning the drive letter, path, and filename: like "C:\Windows\System\MyActiveXControl.OCX" or "C:\Program Files\Application\MyActiveXControl.OCX").

If the file is not located in a static position on every system, you will have to find the path programmatically... If this is what you need, please ask and I will be glad to assist :-)
Otherwise, the solution I provided is what you are looking for...

-Burbble
0
 
LVL 7

Expert Comment

by:Burbble
ID: 12376813
Like I said,

>> Otherwise, the solution I provided is what you are looking for...

Based on the information provided, I am 99% sure that what I provided will solve the problem :)

-Burbble
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Have you ever wanted to restrict the users input in a textbox to numbers, and while doing that make sure that they can't 'cheat' by pasting in non-numeric text? Of course you can do that with code you write yourself but it's tedious and error-prone …
Most everyone who has done any programming in VB6 knows that you can do something in code like Debug.Print MyVar and that when the program runs from the IDE, the value of MyVar will be displayed in the Immediate Window. Less well known is Debug.Asse…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…

734 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