Video Screencast Help
Search Video Help Close Back
to help
Not able to make it to Vision this year? Get a sampling in the Best of Vision on Demand group.

Path Environment Variable: Appended Path not removed on uninstall

Updated: 05 Jun 2010 | 2 comments
berlin's picture
0 0 Votes
Login to vote

Using Wise Installation Express 7, I want my setup to add a path to the Windows System Path Environment Variable on install and remove it on uninstall. Seemed to be easy, I used Installation Expert's section "Environment Variables" and added

Name: Path
Value: [INSTALLDIR]workbench
Operation: Set value on install and delete on uninstall
Replacement: Append at the end of current value
Windows NT based system environment variable is checked.

Works as expected on install, but on uninstall my "[INSTALLDIR]workbench" path never gets removed from the system path environment variable.
In the components table, Environment, it says:
Environment: Path
Name: *=-Path
Value: [~];[INSTALLDIR]workbench

Any hints why my msi does not remove my program's path from Windows path variable on uninstall would be appreciated.

Thanks in advance!

Discussion Filed Under:

Comments

AngelD's picture
04
Dec
2009
0 Votes 0
Login to vote

What does a verbose log

What does a verbose log say?
Did you try to reboot prior to checking the Path environment variable?

EdT's picture
04
Dec
2009
0 Votes 0
Login to vote

What O/S ?

If you are running on Vista or Win 7, do you get the elevation prompt at uninstall?  The system environment variable is stored as a registry key in HKLM and you need admin rights to make changes there. A verbose log of the uninstall, as suggested by AngelD, will certainly give you an indication of what is going on.
Since the environment is cached, a reboot is normally required for the changes to be implemented, so how are you checking whether the value has been removed?  A direct check of the registry key is the most reliable method.
(HKLM/System.CurrentControlSet/Control/SessionManager/Environment)

If your issue has been solved, please use the "Mark as Solution" link on the most relevant thread.