.Net framework - "unable to find a version of the runtime to run this application"
Machine with /Net framework version 4.0 installed m/c (win xp with sp3) (no previous framework version present)
when try to run the program which is compiled in framework previous version of .net framework i.e =>3.5 ,came开发者_如何转开发 across below initialization error "unable to find a version of the runtime to run this application".
on googling found -changing config <startup>
<supportedRuntime version="v4.0.30319" />
</startup>
may help to solve, but that too didn't work. Any help would be appreciated.
I could able to solve this issue. Below info would be a help for someone who is in my situation.
insert below startup tag in your application.config file
<?xml version="1.0"?>
<configuration>
<startup useLegacyV2RuntimeActivationPolicy="true">
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.0"/>
</startup>
</configuration>
May be this blog entry would also be helpful: NET 4.0 and Mixed-mode assemblies
精彩评论