在工作室中打开 CSS 文件时,出现组件错误,编辑器敲掉标记。
ActivityLog.xml 日志文件包含以下信息。
<entry>
<record>746</record>
<time>2017/11/17 18:49:57.319</time>
<type>Error</type>
<source>Editor or Editor Extension</source>
<description>
System.ArgumentNullException: Value cannot be null.
Parameter name: value
at System.Enum.ToObject(Type enumType, Object value)
at Microsoft.VisualStudio.Shell.DialogPage.SetPropertyValue(PropertyDescriptor descriptor, Object automationObject, Object value)
at Microsoft.VisualStudio.Shell.DialogPage.LoadSettingFromStorage(PropertyDescriptor prop)
at Microsoft.VisualStudio.Shell.DialogPage.LoadSettingsFromStorage()
at Microsoft.VisualStudio.Shell.DialogPage.set_Site(ISite value)
at System.ComponentModel.Container.Add(IComponent component, String name)
at System.ComponentModel.Container.Add(IComponent component)
at Microsoft.VisualStudio.Shell.Package.GetDialogPage(Type dialogPageType)
at Microsoft.VisualStudio.Html.Package.Package.CSS.CssPackage.GetAutomationObject(String name)
at Microsoft.VisualStudio.Shell.Package.Microsoft.VisualStudio.Shell.Interop.IVsPackage.GetAutomationObject(String propName, Object& auto)
at Microsoft.VisualStudio.Web.Editor.Package.Settings.Common.WebSettingsStorageWithDialog.LoadFromStorage()
at Microsoft.Web.Editor.Host.WebEditor.GetSettings(String contentTypeName)
at Microsoft.CSS.Editor.Settings.CssSettings.get_Storage()
at Microsoft.CSS.Editor.Settings.CssSettings.get_ValidationEnabled()
at Microsoft.CSS.Editor.Checker.CssErrorTagger..ctor(ITextBuffer textBuffer)
at Microsoft.CSS.Editor.Checker.CssErrorTagger.Attach(ITextBuffer textBuffer)
at Microsoft.CSS.Editor.Checker.CssErrorTaggerProvider.CreateTagger[T](ITextBuffer textBuffer)
at Microsoft.VisualStudio.Text.Tagging.Implementation.TagAggregator`1.GatherTaggers(ITextBuffer textBuffer)
--- End of stack trace from previous location where exception was thrown ---
at Microsoft.VisualStudio.Telemetry.WindowsErrorReporting.WatsonReport.GetClrWatsonExceptionInfo(Exception exceptionObject)
</description>
</entry>
好吧,编辑器页面显示错误。
我尝试禁用和启用组件以使用 ASP.NET,包括 CSS 组件,但没有成功。试图恢复,再次没有。任何想法如何解决这一问题?