全部,
我是 ASP.NET 编程的新手,我正在尝试做一些示例来入门。我在 Xamarin 4.0.8(构建 2)中执行此操作。当我尝试打开Default.aspx
文件(创建项目时生成)时,遇到以下异常警告:
System.Exception: System.Web assembly name not found for framework .NETFramework,Version=v4.5
at MonoDevelop.AspNet.WebTypeContext.GetSystemWebDom(TargetRuntime runtime, TargetFramework targetFramework)
at MonoDevelop.AspNet.WebTypeContext.GetSystemWebDom(AspNetAppProject project)
at MonoDevelop.AspNet.WebTypeContext..ctor(AspNetAppProject project)
at MonoDevelop.AspNet.Parser.DocumentReferenceManager..ctor(AspNetAppProject project)
at MonoDevelop.AspNet.Gui.AspNetEditorExtension.OnParsedDocumentUpdated()
at MonoDevelop.XmlEditor.Gui.BaseXmlEditorExtension.<Initialize>b__0(Object , EventArgs )
at System.EventHandler.Invoke(Object sender, EventArgs e)
at MonoDevelop.Ide.Gui.Document.OnDocumentParsed(EventArgs e)
at MonoDevelop.Ide.Gui.Document.<>c__DisplayClass1c.<>c__DisplayClass1e <>c__DisplayClass20.<StartReparseThread>b__1b(Object , EventArgs )
at Gtk.Application.InvokeCB.Invoke()
at GLib.Timeout.TimeoutProxy.Handler()
此外,我稍后收到此异常:
System.NullReferenceException: Object reference not set to an instance of an object.
at MonoDevelop.AspNet.Gui.AspNetEditorExtension.OnParsedDocumentUpdated()
at MonoDevelop.XmlEditor.Gui.BaseXmlEditorExtension.<Initialize>b__0(Object , EventArgs )
at System.EventHandler.Invoke(Object sender, EventArgs e)
at MonoDevelop.Ide.Gui.Document.OnDocumentParsed(EventArgs e)
at MonoDevelop.Ide.Gui.Document.<>c__DisplayClass1c.<>c__DisplayClass1e.<>c__DisplayClass20.<StartReparseThread>b__1b(Object , EventArgs )
at Gtk.Application.InvokeCB.Invoke()
at GLib.Timeout.TimeoutProxy.Handler()
最终它到达了 IDE 必须关闭的地步。
我尝试将目标框架从 Mono/.NET 4.0 切换到 Mono/.NET 4.5,但无济于事。
似乎它只是没有找到 System.Web 库。我怎么把它指向那里?