wpf 在哪里可以找到 System.Windows.Controls.dll 和 System.Windows.Controls.Data.dll
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/1839620/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Where can I find System.Windows.Controls.dll and System.Windows.Controls.Data.dll
提问by Ivri
I'm using WPF, VS2010 and VS2008
我正在使用 WPF、VS2010 和 VS2008
Are these libraries available with Silverlight only? Is PresentationFramework.dll == System.Windows.Controls.dll?
这些库是否仅适用于 Silverlight?PresentationFramework.dll == System.Windows.Controls.dll?
回答by Webleeuw
I suppose you're looking for the System.Windows.Controls namespace (not the .dll). The namespace you refer to is indeed in PresentationFramework.dll that is part of the Windows SDK from Microsoft (afaik not a standard part of the .Net framework).
我想您正在寻找 System.Windows.Controls 命名空间(不是 .dll)。您引用的命名空间确实在 PresentationFramework.dll 中,它是 Microsoft 的 Windows SDK 的一部分(afaik 不是 .Net 框架的标准部分)。
System.Windows.Controls.Data is in the System.Windows.Controls.Data.dll assembly file.
System.Windows.Controls.Data 位于 System.Windows.Controls.Data.dll 程序集文件中。
The System.Windows.Controls.Data namespace is part of Silverlight, which most recent sourcefiles you can download at: http://www.microsoft.com/downloads/details.aspx?familyid=D09B6ECF-9A45-4D99-B752-2A330A937BC4&displaylang=en
System.Windows.Controls.Data 命名空间是 Silverlight 的一部分,您可以在以下位置下载最新的源文件:http: //www.microsoft.com/downloads/details.aspx?familyid=D09B6ECF-9A45-4D99-B752-2A330A937BC4&displaylang =zh
Both assemblies reside on my pc in "Program Files\Reference Assemblies\Microsoft\Framework\v3.0"
两个程序集都驻留在我的电脑上的“Program Files\Reference Assemblies\Microsoft\Framework\v3.0”中
Edit: wrong Silverlight download link. Corrected :)
编辑:错误的 Silverlight 下载链接。更正:)
It is possible that the Controls.Data dll is not in the recent SilverLight SDK, so if nothing else helps you can find it in an separate download: http://www.microsoft.com/downloads/details.aspx?FamilyID=084A1BB2-0078-4009-94EE-E659C6409DB0&displaylang=en
Controls.Data dll 可能不在最近的 SilverLight SDK 中,所以如果没有其他帮助,您可以在单独的下载中找到它:http: //www.microsoft.com/downloads/details.aspx?FamilyID=084A1BB2 -0078-4009-94EE-E659C6409DB0&displaylang=en
回答by Teddy
I also had this problem, I found the path when I right clicked on the Toolbox in design mode and clicked Choose items... then on Silverlight components tab
我也有这个问题,当我在设计模式下右键单击工具箱并单击选择项目...然后在 Silverlight 组件选项卡上时,我找到了路径
I found it in PROGRAM FILES (x86)\MICROSOFT SDKs\SILVERLIGHT\v5.0\LIBRARIES\CLIENT. Click on file and then click add. What I did was Click on Project on the file menu then add Reference clicked on Browse (bottom of screen) and enter the above path. Hope this will help.
我在 PROGRAM FILES (x86)\MICROSOFT SDKs\SILVERLIGHT\v5.0\LIBRARIES\CLIENT 中找到了它。单击文件,然后单击添加。我所做的是单击文件菜单上的项目,然后添加引用,单击浏览(屏幕底部)并输入上述路径。希望这会有所帮助。
回答by Mike Gledhill
I was having this error with a WPF project (rather than a Silverlight project)
我在 WPF 项目(而不是 Silverlight 项目)中遇到此错误
It was caused by me not having the (quite old) WPFToolkit.dll installed on my new laptop.
这是因为我没有在我的新笔记本电脑上安装(相当旧的)WPFToolkit.dll。