ClickOnce Activation Errors on the PDC Whidbey / Longhorn Build

The PDC build of Whidbey and Longhorn do not provide a great mechanism for handling errors in ClickOnce manifests and other similar activation issues. Often if there is a problem activating a ClickOnce application, you’ll only get a simple error dialog saying “General Activation Error.”

The good news is that we’re actively working on a better error reporting story. The bad news is that you’re currently working on PDC bits and need to figure out what went wrong with your program. The best way to start debugging this is to look at the log file, which is located in %USERPROFILE%\Local Settings\My Applications\System.Deployment.log. This file should be able to help you pinpoint what went wrong during the activation process.

Another place to go to try to solve problems (for non-Longhorn users), is to:
1. delete the %WINDIR%\Microsoft.Net\Framework\v1.2.30703\config\ApplicaitonTrust.config file
2. run %WINDIR%\Microsoft.Net\Framework\v1.2.30703\caspol -all -reset

This will erase the configuration file of application trust decisions and trust manager setup (an incorrectly setup trust manager will cause activation problems), and then reset them to the defaults shiped with Whidbey.

Note that if you are running Longhorn, running caspol -all -reset will set the trust manager to the Whidbey trust manager, instead of the Longhorn one. You’ll want to make a copy of the ITrustManager element from the ApplicatonTrust.config file before you do this, and paste it back into the applicationtrust.config file after the rest, to continue allowing you to use the Longhorn trust manager.

Comments (0)