My ClickOnce application targets the .NET 4 Client Profile to reduce the amount the client's desktop has to download and install over the web.
However, when I click the set-up button on the Publish page it fails with the following error:
There were no warnings during this operation.
OPERATION PROGRESS STATUS
* [12/03/2012 11:37:05] : Activation of C:\Users\me\Downloads\desktopapp.application has started.
* [12/03/2012 11:37:08] : Processing of deployment manifest has successfully completed.
* [12/03/2012 11:37:08] : Installation of the application has started.
* [12/03/2012 11:37:08] : Processing of application manifest has successfully completed.
* [12/03/2012 11:37:29] : Found compatible runtime version 4.0.30319.
* [12/03/2012 11:37:30] : Request of trust and detection of platform is complete.
* [12/03/2012 11:37:33] : Downloading of subscription dependencies is complete.
* [12/03/2012 11:37:33] : Commit of the downloaded application has started.
ERROR DETAILS
Following errors were detected during this operation.
* [12/03/2012 11:37:33] System.Runtime.InteropServices.COMException
- **Failed to load the runtime. (Exception from HRESULT: 0x80131700)**
- Source: System.Deployment
- Stack trace:
at System.Deployment.Application.NativeMethods.GetRequestedRuntimeInfo(String pExe, String pwszVersion, String pConfigurationFile, UInt32 startupFlags, UInt32 runtimeInfoFlags, StringBuilder pDirectory, UInt32 dwDirectory, UInt32& dwDirectoryLength, StringBuilder pVersion, UInt32 cchBuffer, UInt32& dwLength)
The client machine is running Windows 7 and .NET 4 client profile is installed. What might the problem be and how do I resolve it?
I have seen HR
0x80131700
emitted from GetRequestedRuntimeInfo()
when it is called to get a specific version of the .NET run-time. Unfortunately, GetRequestedRuntimeInfo()
does not always return the requested version even if it is installed. More information is in GetRequestedRuntimeInfo Function (MSDN). In this case, consider using the techniques in How to: Determine Which .NET Framework Versions Are Installed instead to determine if the appropriate .NET framework is installed.
User contributions licensed under CC BY-SA 3.0