Mon application a un Target .NET Framework de 3.0.Application .NET Framework 3.0 sous Windows XP SP3 avec .NET Framework 4.0
J'ai un PC avec une nouvelle installation de Windows XP SP3. Ensuite, j'ai installé .NET Framework 4.0 Full sur celui-ci.
Lorsque je tente de lancer mon application ClickOnce déployée, je reçois le « Impossible de charger le moteur d'exécution » erreur:
[9/9/2011 11:39:53 AM] System.Runtime.InteropServices.COMException
- Failed to load the runtime. (Exception from HRESULT: 0x80131700)
- Source: System.Deployment
- Stack trace:
at System.Deployment.Application.NativeMethods.IClrMetaHostPolicy.GetRequestedRuntime(MetaHostPolicyFlags policyFlags, String binaryPath, IStream configStream, StringBuilder version, Int32& versionLength, StringBuilder imageVersion, Int32& imageVersionLength, Int32& pdwConfigFlags, Guid interfaceId)
at System.Deployment.Application.NativeMethods.GetAssemblyCacheInterface(String CLRVersionString, Boolean FetchRuntimeHost, CCorRuntimeHost& RuntimeHost)
at System.Deployment.Application.PlatformDetector.VerifyPlatformDependencies(AssemblyManifest appManifest, AssemblyManifest deployManifest, String tempDir)
at System.Deployment.Application.ApplicationActivator.DownloadApplication(SubscriptionState subState, ActivationDescription actDesc, Int64 transactionId, TempDirectory& downloadTemp)
at System.Deployment.Application.ApplicationActivator.InstallApplication(SubscriptionState& subState, ActivationDescription actDesc)
at System.Deployment.Application.ApplicationActivator.PerformDeploymentActivation(Uri activationUri, Boolean isShortcut, String textualSubId, String deploymentProviderUrlFromExtension, BrowserSettings browserSettings, String& errorPageUrl)
at System.Deployment.Application.ApplicationActivator.ActivateDeploymentWorker(Object state)
Je crois comprendre que les applications de ciblage .NET 3.0 devrait fonctionner sur les machines qui ont .NET 4.0 installé. Qu'est ce qui cause cette erreur? Dois-je installer .NET Framework 3.5 SP1 sur les ordinateurs Windows XP?
Je pense que je peux écrire un prérequis personnalisé et A) [Vérifier si l'utilisateur a .NET Framework 3.0 installé] (http://stackoverflow.com/questions/199080/how-to-detect-what-net-framework- versions-et-service-packs-sont-installés). (frais XP ne l'aura pas, frais Vista l'aura, frais Win 7 l'aura) B) Si .NET 3 n'est pas installé, installez 3.5. – yarone
OK, cela a fonctionné. Pourquoi l'application ne fonctionne pas correctement (sur XP SP3 avec .NET 4.0) n'a pas de sens pour moi. – yarone