2016-09-17 94 views
0

設計器的工作原理與正常情況相似嗎?那麼突然,我收到一條錯誤消息。Visual Studio 2015設計器中的System.ArgumentException

System.ArgumentException 
An item with the same key has already been added. 
    at System.ThrowHelper.ThrowArgumentException(ExceptionResource resource) 
    at System.Collections.Generic.Dictionary`2.Insert(TKey key, TValue value, Boolean add) 
    at System.Collections.Generic.Dictionary`2.Add(TKey key, TValue value) 
    at Microsoft.VisualStudio.DesignTools.Utility.Telemetry.VsTelemetryService.RegisterDesignerProcessSession(Int32 pid) 
    at Microsoft.VisualStudio.DesignTools.Utility.Feedback.WatsonTracker.RegisterSession(Int32 processID) 
    at Microsoft.VisualStudio.DesignTools.Utility.DesignerSessionTracker.RecordDesignerStart(Int32 processID, String isolationTargetIdentifier, Boolean mockCustomTypes, String buildConfiguration) 
    at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.Primitives.ProcessDomainFactory.ProcessIsolationDomain..ctor(ProcessDomainFactory factory, IIsolationBoundary boundary, AppDomainSetup appDomainInfo, IIsolationTarget isolationTarget, String baseDirectory) 
    at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.Primitives.ProcessDomainFactory.CreateIsolationDomain(IIsolationBoundary boundary) 
    at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.Primitives.IsolationBoundary.Initialize() 
    at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.Primitives.IsolationBoundary.CreateInstance[T](Type type) 
    at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.IsolatedObjectFactory.Initialize() 
    at Microsoft.VisualStudio.DesignTools.DesignerHost.Services.VSIsolationService.CreateObjectFactory(IIsolationTarget isolationTarget, IObjectCatalog catalog) 
    at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.IsolationService.CreateLease(IIsolationTarget isolationTarget) 
    at Microsoft.VisualStudio.DesignTools.DesignerContract.IsolatedDesignerService.CreateLease(IIsolationTarget isolationTarget, CancellationToken cancelToken, DesignerServiceEntry& entry, IServiceProvider serviceOverrides) 
    at Microsoft.VisualStudio.DesignTools.DesignerContract.IsolatedDesignerService.IsolatedDesignerView.CreateDesignerViewInfo(CancellationToken cancelToken) 
    at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.IsolatedTaskScheduler.InvokeWithCulture[T](CultureInfo culture, Func`2 func, CancellationToken cancelToken) 
    at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.IsolatedTaskScheduler.<>c__DisplayClass10_0`1.<StartTask>b__0() 
    at System.Threading.Tasks.Task`1.InnerInvoke() 
    at System.Threading.Tasks.Task.Execute() 

所以,我就像:好的。只是一個簡單的信息,沒什麼。所以我嘗試尋找解決方案。沒有。我一直在尋找四天,試圖讓這個工作。但它沒有。我試圖修復,卸載然後重新安裝,我甚至嘗試了devenv/resetuserdata和devenv.exe/safemode,仍然無法正常工作。即使試圖創建一個新用戶,然後嘗試它。沒有。我花了很長時間安裝15'更新,仍然沒有。錯誤不會消失。我甚至在Blend嘗試它!仍然不起作用。我甚至安裝了Windows 10週年紀念更新!仍然無法工作。

有人可以幫忙。

+0

安裝VS2015 upd3的最新更新,它包含XAML設計器修正:https://msdn.microsoft.com/en-US/library/mt752379.aspx – magicandre1981

+0

仍然無法正常工作。 – user3831089

+0

以安全模式運行V:https://msdn.microsoft.com/en-us/library/ms241278.aspx – magicandre1981

回答

0

我通過刪除運行程序的驅動器中名爲「程序」的文件來修復它。