The. NET Framework Client profile is a cropped version of the. NET Framework. It is intended for client applications. It provides a simplified subset of Windows Presentation Foundation (WPF), Windows Forms, Windows Communication Foundation (WCF), and ClickOnce features. This enables rapid deployment scenarios for WPF, Windows forms, WCF, and console applications that target the. NET Framework Client profile.
See: Http://msdn.microsoft.com/zh-cn/library/cc656912.aspx
In VS2010, the WPF program you set up by default is the. NET Framework 4 Client profile, not the. NET Framework 4. Yesterday afternoon to this morning, I was in for the system.web can not cite the problem of distress, is that it caused.
In VS2010, we can see that the project has the following multiple Target framework properties under the project's properties.
The Sytem.web I came across today refer to the following questions:
When writing a WPF application with VS2010 Beta2, the System.Web.HttpUtility.UrlEncode () method was used to find that the reference to system.web could not be increased. The following figure:
There are no system.web components in. NET Reference.
Open a file of the specified directory using the Browse method C:\Windows\Microsoft.NET\Framework\v4.0.21006\System.Web.dll.
The following figure:
There is also no 4.0 version of the System.Web component in the GAC, as shown in the following figure:
An error is reported when you force add C:\Windows\Microsoft.NET\Framework\v4.0.21006\System.Web.dll to the GAC:
---------------------------
Cant Add Assembly
---------------------------
Unable to add the selected assembly. The Assembly moment-in have a fervent name (name, version and public key).
---------------------------
Are you sure
---------------------------
The information for this file is as follows:
But the WEB project that VS2010 Beta2 built, by default, has system.web references, and there is no problem here, as shown in the following figure:
Look at this system.web property as follows:
Put C:\Program files\reference Assemblies\microsoft\framework\. Netframework\v4.0\system.web.dll into the GAC will also report errors:
---------------------------
Cant Add Assembly
---------------------------
Unable to add the selected assembly. The Assembly moment-in have a fervent name (name, version and public key).
---------------------------
Are you sure
---------------------------
The WPF program points to the file's reference alone, as is the case above. Also the error.
The problem I encountered above is simply to modify the Target framework of the project to the. Net Framework 4.