2017-02-15 168 views
8

我最近安裝了Xamarin。我在一週內沒有遇到任何問題。現在,當我加載視覺工作室時,出現如下提示:InspectorPackage沒有正確加載

'InspectorPackage'包未正確加載。

問題可能是由配置更改或安裝其他擴展引起的。您可以通過檢查文件 'C:\ Users {redacted} \ AppData \ Roaming \ Microsoft \ VisualStudio \ 14.0 \ ActivityLog.xml'來獲取更多信息。

重新啓動Visual Studio可以幫助解決此問題。

繼續顯示此錯誤消息?

重新啓動Visual Studio不能解決此問題。

在檢查XML文件中,我發現:

<entry> 
    <record>503</record> 
    <time>2017/02/15 15:33:56.686</time> 
    <type>Error</type> 
    <source>VisualStudio</source> 
    <description>LegacySitePackage failed for package [InspectorPackage]Source: 
     &apos;&apos; Description: Not implemented 
     (Exception from HRESULT: 0x80004001 (E_NOTIMPL))&#x000D;&#x000A; 
     System.NotImplementedException: Not implemented 
     (Exception from HRESULT: 0x80004001 (E_NOTIMPL))&#x000D;&#x000A; 
     at EnvDTE.Project.get_FullName()&#x000D;&#x000A; 
     at Xamarin.Inspector.VS.VSAgentExecutionTarget..ctor(Project proj)&#x000D;&#x000A; 
     at Xamarin.Inspector.VS.VSInspectorSession.CreateAgentExecutionTarget()&#x000D;&#x000A; 
     at Xamarin.Interactive.IdeSupport.InspectorSession.Prepare()&#x000D;&#x000A; 
     at Xamarin.Inspector.VS.InspectorPackage.RefreshInspectorSession()&#x000D;&#x000A; 
     at Xamarin.Inspector.VS.InspectorPackage.Initialize()&#x000D;&#x000A; 
     at Microsoft.VisualStudio.Shell.Package.Microsoft.VisualStudio.Shell.Interop.IVsPackage.SetSite(IServiceProvider sp) 
    </description> 
    <guid>{0FCBA9C6-0554-418C-8B79-FF2ED7DC658D}</guid> 
    <hr>80004001 - E_NOTIMPL</hr> 
    <errorinfo></errorinfo> 
</entry> 

我能做些什麼來解決這個問題?

回答

7

此錯誤似乎只在解決方案中有多個啓動項目時纔會顯示。

我通過創建一個帶有兩個空控制檯項目的空解決方案來複制它。當只有一個設置爲啓動時,一切正常。但是,當設置爲啓動時,這個錯誤會彈出。

我也碰到這個錯誤哪兒來的2017年1月14日過去後指出,即將到來的版本1.1版本將解決這個問題:https://bugzilla.xamarin.com/show_bug.cgi?id=49417

您可以在VS.關於對話框檢查版本在VS2015上,它是幫助|關於微軟Visual Studio,我估計它是Xamarin Inspector Support條目。煤礦是1.0.0.0,所以我認爲我將不得不等待即將發佈的:)

更新

奇怪的是,更新剛到了Xamarin督察(小於30分鐘後回答)。我的測試解決方案的第一個負載仍然彈出錯誤,但之後似乎很好。

更新(2017年2月28日)

我仍然遇到以下版本的問題: Xamarin Inspector Support 1.1.2.0 (cdc01b9f4466b6dcc3095828824a12d041c9f55e) Adds support for inspecting Xamarin and WPF apps.

0

這是我做過什麼和它的工作對我來說:

1)轉到Visual Studio的路徑並刪除該文件夾中的所有內容 (這會刪除您設置的Visual Studio)Visual Studio在此之後不會工作 C:\Users\<username>\AppData\Local\Microsoft\VisualStudio

2)卸載Visual Studio。並再次安裝它。

如果這不起作用,請在該文件夾中查找xamarin文件並刪除裏面的所有文件。