可以将System.Windows.Forms添加到WinRT项目中吗?

msb*_*sbg 2 c# reference winforms windows-8 windows-runtime

我想添加一个类库,使用System.Windows.Forms命名空间到我的Windows 8应用程序.当我添加命名空间并构建解决方案时,我收到一个错误:

 Cannot find type System.Resources.ResourceSet in module mscorlib.dll.
Run Code Online (Sandbox Code Playgroud)

是否可以添加System.Windows.Forms?

Dam*_*Arh 7

不,System.Windows.FormsWindows应用商店应用不支持.以下是其中所有受支持的.NET命名空间和类的列表.

您不能仅从Windows应用商店应用引用现有的.NET程序集.它们需要是便携式类库或Windows应用商店应用程序的类库.