Home » .Net FrameworkRSS

troubleshooting a .NET/WPF 4.0 application requiring 3.5 SP1 to run

I am very confused what is going on with my application.

I have a complex C++/CLI and WPF application that I've migrated to .NET 4 to take advantage of the WPF goodies. I'm having problems though with the deployment and running of our app on fresh XP installs.

Right now the installer will install the Visual C++ 2010 redist and .Net 4 client profile, then our application. On XP this doesn't seem to be enough. In it's current state it will crash upon running the .exe. By chance I guessed perhaps our CLI based .dll has some dependencies on some old libs, so I also installed the Visual C++ 2008 redist. Now when I run I see the splash screen for our application, but I get an error dialog that says:

"To run this application, you first must install one of the following versions of the .NET Framework: 2.0.50727"

If I click the yes button it redirects me to install .Net 4 again. For kicks I tried installing the .NET 3.5 SP1 framework and my application runs.

How can I troubleshoot what is going on?

 

4 Answers Found

 

Answer 1

If I run  the application  on my Win7 developer machine (with all .NETs installed) I can one reference to a .NET 2.0 lib. 

 

'Kudu.exe': Loaded 'C:\Windows\SysWOW64\WindowsCodecs.dll', Exports loaded.

'Kudu.exe': Loaded 'C:\Windows\Microsoft.NET\Framework\v2.0.50727\mscorwks.dll', Exports loaded.

'Kudu.exe': Loaded 'C:\Windows\winsxs\x86_microsoft.vc80.crt_1fc8b3b9a1e18e3b_8.0.50727.4927_none_d08a205e442db5b5\msvcr80.dll', Exports loaded.

Any reason why this is pointing to the old lib?

 

Answer 2

Check your references (either in vs.net or use reflector on your binaries) and perhaps your config file to see if they reference they 2.x framework.

 

Answer 3

The only assemblies not for runtime v.40.30319 are the Microsoft Office interop tools included with VS2010. Both these say they use runtime version 1.1. In addition i'm using Microsoft.mshtml which uses 1.0. These have to be supported in .net 4 though, don't they?
 

Answer 4

Found it. I'm using StrongName.h to check the signing of my assemblies. Have to use ICLRStrongName now, which there's no documentation how to.... 
 
 
 

<< Previous      Next >>


Microsoft   |   Windows   |   Visual Studio   |   Follow us on Twitter