How do I completely uninstall a ClickOnce applicat

2019-03-08 03:27发布

While experimenting with trying to publish both a Foo and Foo Beta version of my application via ClickOnce I managed to clobber the existing and previously-working-fine Foo 1.0.0 install (replacing it with Foo Beta 1.0.5, which does not work) due to using the same GUID, assembly name, product name or something.

OK, honest mistake. In an attempt to revert this I then uninstalled Foo Beta using the Windows 7 add/remove programs.

My computer is now in a state where no instance of Foo shows up in Windows 7 Add/Remove programs. However, Foo Beta is still shown as installed. In addition, I am unable to re-install Foo 1.0.0, because it thinks that a newer version of the program (Foo Beta 1.0.5) already exists on my computer - instead I get the `Unable to install because a newer version of this product is already installed' message.

How can I get my computer to a state where neither Foo nor Foo Beta have ever been installed on it, so that I can then go and re-install Foo?

So far I have read Stack Overflow questions Uninstall ClickOnce clients and How can I remove all traces of a ClickOnce application from a customer's computer? and tried:

  1. Deleting all the relevant foo.exe directories under %USERPROFILE%/
  2. Running mage.exe -cc
  3. Editing the HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Uninstall and removing the entry for my Foo program.

When I run the installer, I still get the error. Where is it finding traces of my program from? And for future reference, where is this documented?

4条回答
Ridiculous、
2楼-- · 2019-03-08 04:07

1) Run rundll32 %SystemRoot%\system32\dfshim.dll CleanOnlineAppCache

2) You might have to manually delete the ClickOnce deployment folders,

  • On Windows Vista or higher, this will be the %LocalAppData%\Apps\2.0 directory.
  • On Windows XP this will be the %USERPROFILE%\Local Settings\Apps\2.0 directory.

3) You might also have to logout and login back

查看更多
闹够了就滚
3楼-- · 2019-03-08 04:12

You can try using this command to clear the ClickOnce cache:

rundll32 dfshim CleanOnlineAppCache
查看更多
兄弟一词,经得起流年.
4楼-- · 2019-03-08 04:19

DO IT THE OLD WAY! :D

use the "old" control panel to remove the Click Once app and re-install it. Do not use the "new " Windows Ten/2016 interface

EG this is GOOD and will remove Click Once:

Start => type
Control Panel\Programs\Programs and Features

enter image description here

EG this is BAD and will get you in a circular hell if you use it to remove Click Once:

Start => Run =>
ms-settings:

enter image description here

查看更多
别忘想泡老子
5楼-- · 2019-03-08 04:23

Deleting all the relevant foo.exe directories under %USERPROFILE%/

You should also look inside manifests folder

查看更多
登录 后发表回答