all groups > visual studio .net setup > february 2007 >
You're in the

visual studio .net setup

group:

Remove and Unregister in a project


Remove and Unregister in a project cbtechlists NO[at]SPAM gmail.com
2/15/2007 10:33:03 AM
visual studio .net setup:
How do I remove files/directories already on the machine that I want
to install a new app on using a Visual Studio setup project? Also, how
do I unregister a .dll.

I want to remove a folder and all it's files:
c:\testfolder

and I want to unregister a file
c:\testfolder\file.dll

before I install my application. The folders and files I'm removing
are not used by my application, and neither is the .dll. The
'file.dll' was originally registered using a VS Setup project
(vsdrfCOMSelfReg).

Thanks!

Chris
Re: Remove and Unregister in a project Phil Wilson
2/15/2007 1:12:33 PM
If the COM Dll was originally installed with a setup project, then why not
just uninstall that product? That will remove the files and unregister the
COM Dll. You can't just remove those files with out uninstalling the product
that installed them. If you've just got a new version of a setup, use
RemovePreviousVersions to automatically uninstall that old version of the
product when you install the new one.
--
Phil Wilson
[Microsoft MVP Windows Installer]

[quoted text, click to view]

Re: Remove and Unregister in a project cbtechlists NO[at]SPAM gmail.com
2/16/2007 5:45:15 AM
Hi Phil:

I'm trying to combine the removal of an already installed app and
install a new version with another app in the same setup project. How
would I run the uninstall from a setup project? The new setup is not
just an upgrade of the original app. It installs an update (to new
location) of the original app and installs another app, too.

Background:
We original had an install for SQLDMO installed on the machines via a
VS.NET setup project. This is used with an Access Data Project (which
was installed separately). Now I want to combine the install for
SQLDMO (and move it to the same directory as the ADP) with the ADP. So
the installs are going to be different.

Thanks for your help!

Chris

On Feb 15, 4:12 pm, "Phil Wilson"
[quoted text, click to view]
Re: Remove and Unregister in a project Phil Wilson
2/22/2007 1:06:15 PM
If the previous version was installed with MSI and you know it's UpgradeCode
(and version) you can use the RemovePreviousVersions property. That
automatically uninstalls the older version if it's there and then installs
your new version.
--
Phil Wilson
[Microsoft MVP Windows Installer]
[quoted text, click to view]

AddThis Social Bookmark Button