• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 144
  • Last Modified:

Uninstalling a program from code

I'm using Visual Basic 6.  What I am trying to do is write a utility/routine to uninstall my program and then reinstall it from a specified location where I post updated install packages for the program.

Can someone show me some code or point me in the right direction for how to uninstall a program from code?

Thanks
0
AaronNance
Asked:
AaronNance
1 Solution
 
bingieCommented:
Define "uninstall"...

Has you program registered dll's or added it's self to the add/remove program list?

If not - there really isn't any uninstalling necessary - just delete the original .exe and save the new one.
0
 
AaronNanceAuthor Commented:
There are a number of DLLs and it is in the Add/Remove Programs list.  If there was a way to trigger the add/remove program functionality then I think that would probably be the answer I need, however I don't how to do it or if it is possible.
0
 
Naveen SwamyCommented:
hi,
the best way to do is to create an exe, in that exe
1) u will first download all the required files and then
2) close all running applications tht are using ur application
3) unregister the dll (old), delete all references
4) register new dlls, update ur application
5) and its done

to call your dlls u need to enter your exe name in the uninstall string in the
hkeylm\softwares\microsoft\windows\currentversion\uninstall\urkey\
and in the
uninstallstring
write the path of ur updater exe

Regards,
M.Naveen Swamy
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now