我使用Visual Studio 2013专业版,C#语言编写,我的代码中有以下引用和一行代码:
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
this.Width = System.Windows.SystemParameters.PrimaryScreenWidth;
然而,它出现了一个错误,如下所示:“The type or namespace name 'SystemParameters' does not exist in the namespace 'System.Windows' (are you missing an assembly reference?)”。
我并不真正理解发生了什么,我应该添加更多内容以使用systemparameters吗?