ClickOnce installing old assemblies from cache

I am using ClickOnce to install my application written in C #. Everything went fine until the last update, after which the start of my application ends with an error:

Could not load file or assembly MyAssembly ... HRESULT: 0x80131040.

After some research, I discovered that there is an old version of MyAssembly located in my application's ClickOnce cache folder (C: \ Documents and Settings .. \ Apps \ 2.0 ...). However, there is a real version in the deployment package.

I also found this old version of MyAssembly in a standalone directory in the ClickOnce cache named after this assembly (plus some added symbols).

It seems to me that for some reason ClickOnce was using this old version of MyAssembly from the cache instead of the new version from the deployment package.

Removing / installing my app won't help.

How is this possible?

+1


a source to share


2 answers


I had the same behavior. He mentioned the problem in another question. Since then, this has happened several times for us with different applications. One strange thing is that it behaves differently on different computers. Thus, one computer could be updated with a new build, while the other received an old copy.

.NET ClickOnce Injection and Wrong Assemblies Called after Version Upgrade



This appears to be a bug in the .NET framework 3.5 SP1.

See Microsoft KB 971052.

+2


a source


Make sure this old assembly is loaded. You can use DllProfiler for this.



0


a source







All Articles