我在某些样式/模板化XAML代码中收到了“对象引用未设置为对象实例”。我做了什么what this guy suggested并附加了第二个Visual Studio实例来调试它。果然,当我做了一个空白变化并保存它时,这个异常弹出。XAML DesignSurface未将对象引用设置为对象实例
但是,它并不像它有什么帮助。这里的内NullReferenceException异常的堆栈跟踪:
在Microsoft.Expression.DesignSurface.View.SceneView.SaveGuidesForDocument() 在Microsoft.Expression.DesignSurface.View.SceneView.PrepareDocumentForSaving() 在Microsoft.Expression.DesignHost.Isolation .Remoting.RemoteDesignerView。 <Microsoft.Expression.DesignHost.Isolation.Remoting.IRemoteDesignerView.PrepareDocumentForSaving> b__18() 在Microsoft.Expression.DesignHost.Isolation.Remoting.STAMarshaler.Call.InvokeWorker()
而这里的所有的休息:
如何判断我的代码中的哪个错误导致了这个NullReferenceException?