So that error started appearing for no apparent reason.
I looked at these two similar threads with no avail:
The “XamlCTask” task failed unexpectedly in Xamarin
The “XamlCTask” task failed unexpectedly on visual studio for xamarin
My issue seems to be related specifically to the "Tapped" event. I remove all tapped references and the app compiles.
Here are the errors in order:
Severity Code Description Project File Line Suppression State
Error Position 29:44. No property, bindable property, or event found for 'Tapped'
MeetnGreet C:\Users\chris\documents\visual studio 2015\Projects\MeetnGreet\MeetnGreet\MeetnGreet\MeetnGreet.MainPage.xaml 29
Then I do a clean, build and attempt to run....
Severity Code Description Project File Line Suppression State
Error The "XamlCTask" task failed unexpectedly.
System.ArgumentException: An item with the same key has already been added.
Server stack trace:
at System.ThrowHelper.ThrowArgumentException(ExceptionResource resource)
at System.Collections.Generic.Dictionary2.Insert(TKey key, TValue value, Boolean add)
at Mono.Cecil.Pdb.PdbReader.PopulateFunctions()
at Mono.Cecil.Pdb.PdbReader.ProcessDebugHeader(ImageDebugDirectory directory, Byte[] header)
at Mono.Cecil.ModuleDefinition.ProcessDebugHeader()
at Mono.Cecil.ModuleDefinition.ReadSymbols(ISymbolReader reader)
at Mono.Cecil.ModuleReader.ReadSymbols(ModuleDefinition module, ReaderParameters parameters)
at Mono.Cecil.ModuleReader.CreateModuleFrom(Image image, ReaderParameters parameters)
at Mono.Cecil.ModuleDefinition.ReadModule(Stream stream, ReaderParameters parameters)
at Mono.Cecil.ModuleDefinition.ReadModule(String fileName, ReaderParameters parameters)
at Xamarin.Forms.Build.Tasks.XamlCTask.Compile(IList1 thrownExceptions)
at Xamarin.Forms.Build.Tasks.XamlCTask.Execute()
at System.Runtime.Remoting.Messaging.StackBuilderSink._PrivateProcessMessage(IntPtr md, Object[] args, Object server, Object[]& outArgs)
at System.Runtime.Remoting.Messaging.StackBuilderSink.SyncProcessMessage(IMessage msg)
Exception rethrown at [0]:
at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)
at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)
at Microsoft.Build.Framework.ITask.Execute()
at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute()
at Microsoft.Build.BackEnd.TaskBuilder.d__26.MoveNext() MeetnGreet
Along with error....
Severity Code Description Project File Line Suppression State
Error Position 29:44. No property, bindable property, or event found for 'Tapped'
MeetnGreet C:\Users\chris\documents\visual studio 2015\Projects\MeetnGreet\MeetnGreet\MeetnGreet\MeetnGreet.MainPage.xaml 29
Severity Code Description Project File Line Suppression State
Error The "ResolveLibraryProjectImports" task failed unexpectedly.
System.IO.FileNotFoundException: Could not load assembly 'MeetnGreet, Version=0.0.0.0, Culture=neutral, PublicKeyToken='.
Perhaps it doesn't exist in the Mono for Android profile?
File name: 'MeetnGreet.dll'
at Java.Interop.Tools.Cecil.DirectoryAssemblyResolver.Resolve(AssemblyNameReference reference, ReaderParameters parameters)
at Java.Interop.Tools.Cecil.DirectoryAssemblyResolver.Resolve(String fullName, ReaderParameters parameters)
at Java.Interop.Tools.Cecil.DirectoryAssemblyResolver.Resolve(String fullName)
at Java.Interop.Tools.Cecil.DirectoryAssemblyResolver.GetAssembly(String fileName)
at Xamarin.Android.Tasks.ResolveLibraryProjectImports.Extract(DirectoryAssemblyResolver res, ICollection1 jars, ICollection1 resolvedResourceDirectories, ICollection1 resolvedAssetDirectories, ICollection1 resolvedEnvironments)
at Xamarin.Android.Tasks.ResolveLibraryProjectImports.Execute()
at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute()
at Microsoft.Build.BackEnd.TaskBuilder.d__26.MoveNext() MeetnGreet.Android
I think all this translates to is that my forms package is corrupt. However, I am not exactly sure how to go through a clean repair or reinstall using nuget. I have never had to do it before.
Here is what the packages folder for the project looks like for ref. (because of the discussion on the other thread)
Also, disabling the compiler didn't fix the issue (ref the other threads possible solutions)
Any help would be appreciated.
Let me preface this by saying I have only been working with Xamarin for 2 weeks and am still working through some tutorials. That being said, this error is all my fault.
What happened was, I had been using a table view in my working examples and decided to see how grids worked. So I "converted" the tableview cells to entrycells to entry, textcells to labels surrounded by stacked views, etc...
I made an assumption that the Tapped event was everywhere so I never stopped to check if it was available in a stackview for example. I was just moving things around and the intellisense wasn't throwing up any warnings so I assumed everything was ok.
Hence the compiler crash and now the second error of no property makes complete sense now by itself and was not a result of the compiler crashing which is what I had originally thought.
Sorry for sending up a false flag. Seemed like a much larger issue that it was.
Related
The xaml visual designer crashes for all WIN10 UWP projects, including ones created from the standard template with no code added. I don't know when it started because I thought it was a problem with my project until I tried creating some new ones. The error is given below and in the screen shot at the bottom.
System.Runtime.InteropServices.COMException
The app didn't start. (Exception from HRESULT: 0x8027025B)
at Microsoft.VisualStudio.DesignTools.HostUtility.AppPackage.AppPackageNativeMethods.IApplicationActivationManager.ActivateApplication(String appUserModelId, String activationContext, ActivateOptions options, Int32& processId)
at Microsoft.VisualStudio.DesignTools.HostUtility.AppPackage.DesignerWrtUtility.ActivateApplication(String appUserModelId, String activationContext, Object site, Boolean isRunningElevated)
at Microsoft.VisualStudio.DesignTools.HostUtility.Platform.AppContainerProcessDomainFactory.ActivateApplicationInternal(String appUserModelId, String activationContext, Object site)
at Microsoft.VisualStudio.DesignTools.HostUtility.Platform.AppContainerProcessDomainFactory.CreateDesignerProcess(String applicationPath, String clientPort, Uri hostUri, IDictionary environmentVariables, Int32& processId, Object& processData)
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.HostUtility.Platform.AppContainerProcessDomainFactory.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.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()
I have tried the following:
Running as administrator
Disabling Project Code
Clearing the \Designer\ShadowCache folder
Adding read permissions to the HKEY_CLASSES_ROOT for All Application Packagesas well as C:\Windows.
Running the visual studio repair.
I am not using TrueCrypt (people with similar issues were)
I have tried changing the platform target to ARM, x64 and x86 (rebuilding and reloading after each)
None of these have fixed the issue. I get the same error in blend. Any ideas?
A reinstall of the latest Windows 10 SDK should fix this problem. This can be gathered from Microsoft I've had many issues like this in the past. Certain versions tend to be buggy.
I am Experiencing the following error with:
- Visual Studio 2013 Ultimate Update 1 (Same with Update 3)
- Windows 10 TP Build 9860
- Windows Store Apps Only (No error with a WPF Desktop Application).
Error Decription:
- UI XAML Designer doesn't work (see attached exception)
- Intellisense in the XAML file doesn't work (no suggestion showed up).
System.Exception
Install failed. Please contact your software vendor.
Deployment Register operation with target volume C: on Package App.aa5630c6a.a99c1.a41a2.aaba0.ac20dd792d3d9_1.0.0.0_x86_NorthAmerica_8wekyb3d8bbwe from: (C:\Users\Diego\AppData\Local\Microsoft\VisualStudio\12.0\Designer\ShadowCache\hwvetbdr.ucs\pfhjajzj.4bs\AppXManifest.xml) failed with error 0x80070002. See http://go.microsoft.com/fwlink/?LinkId=235160 for help diagnosing app deployment issues.
at Microsoft.Expression.HostUtility.Platform.AppContainerProcessDomainFactory.CreateDesignerProcess(String applicationPath, String clientPort, Uri hostUri, IDictionary environmentVariables, Int32& processId, Object& processData)
at Microsoft.Expression.DesignHost.Isolation.Primitives.ProcessDomainFactory.ProcessIsolationDomain..ctor(ProcessDomainFactory factory, IIsolationBoundary boundary, AppDomainSetup appDomainInfo, FrameworkName targetFramework, String identifier, String baseDirectory)
at Microsoft.Expression.DesignHost.Isolation.Primitives.ProcessDomainFactory.CreateIsolationDomain(IIsolationBoundary boundary)
at Microsoft.Expression.HostUtility.Platform.AppContainerProcessDomainFactory.CreateIsolationDomain(IIsolationBoundary boundary)
at Microsoft.Expression.DesignHost.Isolation.Primitives.IsolationBoundary.Initialize()
at Microsoft.Expression.DesignHost.Isolation.Primitives.IsolationBoundary.CreateInstance[T](Type type)
at Microsoft.Expression.DesignHost.Isolation.IsolatedObjectFactory.Initialize()
at Microsoft.VisualStudio.ExpressionHost.Services.VSIsolationService.CreateObjectFactory(IIsolationTarget isolationTarget, IObjectCatalog catalog)
at Microsoft.Expression.DesignHost.Isolation.IsolationService.CreateLease(IIsolationTarget isolationTarget)
at Microsoft.Expression.DesignHost.Isolation.IsolationService.CreateLease(IIsolationTarget isolationTarget)
at Microsoft.Expression.DesignHost.IsolatedDesignerService.CreateLease(IIsolationTarget isolationTarget, CancellationToken cancelToken, DesignerServiceEntry& entry)
at Microsoft.Expression.DesignHost.IsolatedDesignerService.IsolatedDesignerView.CreateDesignerViewInfo(CancellationToken cancelToken)
at Microsoft.Expression.DesignHost.Isolation.IsolatedTaskScheduler.InvokeWithCulture[T](CultureInfo culture, Func`2 func, CancellationToken cancelToken)
at Microsoft.Expression.DesignHost.Isolation.IsolatedTaskScheduler.<>c__DisplayClassa`1.<StartTask>b__6()
at System.Threading.Tasks.Task`1.InnerInvoke()
at System.Threading.Tasks.Task.Execute()
Uninstalling and re-installing didn't fix it.
Has anyone experienced it ?
Edit:
Also property tab is blank for every XAML Control
Windows 10 is currently a technical preview and is not meant for you to develop up on, you need o wait for the Windows 10 Developer Preview so that you can start coding on Windows 10 (which will probably come out near the BUILD 2015 event in my opinion).
As they say here: http://technet.microsoft.com/en-US/windows/dn798751.aspx?ocid=wc-mscom-wol
"Windows 10 Technical Preview for Enterprise is an early look at some of the features and functionality in store for Windows 10, the next version of the Windows client operating system. This page offers resources to help you explore Technical Preview for Enterprise, assess the compatibility of your applications, and test the new in-place upgrade process."
From what i understand from this, it is mainly for you to test your apps and company apps on the OS to see if your company will be able to migrate on this or not and not for your to start coding.
Good Luck!
EDIT:
Went you look at the TechNet forum: https://social.technet.microsoft.com/Forums/en-US/home?category=WinPreview2014
you can see that they are mainly looking a bugs with the OS and not about how to develop apps.
I'm getting an error message every time I start Visual Studio. Since I'm also seeing some unexplained behavior in my project, I'd like to resolve this issue.
Error Message
An exception has been encountered. This may be caused by an extension.
You can get more information by examining the file 'C:\Users\Jonathan\AppData\Roaming\Microsoft\VisualStudio\11.0\ActivityLog.xml'.
When I look at the log file, I find two exceptions:
Error 1
Exception Type : System.Windows.Markup.XamlParseException
Exception Message : Provide value on 'System.Windows.StaticResourceExtension' threw an exception.
Exception Stack Trace:
at System.Windows.Markup.WpfXamlLoader.Load(XamlReader xamlReader, IXamlObjectWriterFactory writerFactory, Boolean skipJournaledProperties, Object rootObject, XamlObjectWriterSettings settings, Uri baseUri)
at System.Windows.Markup.WpfXamlLoader.LoadBaml(XamlReader xamlReader, Boolean skipJournaledProperties, Object rootObject, XamlAccessLevel accessLevel, Uri baseUri)
at System.Windows.Markup.XamlReader.LoadBaml(Stream stream, ParserContext parserContext, Object parent, Boolean closeStream)
at System.Windows.Application.LoadComponent(Object component, Uri resourceLocator)
at SquaredInfinity.VSCommands.UI.Views.DefaultAlertView.InitializeComponent()
at SquaredInfinity.VSCommands.Foundation.Services.VSCUIService.GetDefaultAlertViewModel(String alertMessage, String alertDialogTitle)
at SquaredInfinity.Foundation.Presentation.Services.UIService.GetDefaultAlertViewModel(String alertMessage)
at SquaredInfinity.Foundation.Presentation.Services.UIService.ShowAlert(String message)
at SquaredInfinity.VSCommands.VSCommandsPackage.Initialize()
Exception Data : [EmptyOrNull]
Inner Exception:
Exception Type : System.Exception
Exception Message : Cannot find resource named 'VSC.Button'. Resource names are case sensitive.
Exception Stack Trace: at System.Windows.StaticResourceExtension.ProvideValueInternal(IServiceProvider serviceProvider, Boolean allowDeferredReference)
at System.Windows.StaticResourceExtension.ProvideValue(IServiceProvider serviceProvider)
at MS.Internal.Xaml.Runtime.ClrObjectRuntime.CallProvideValue(MarkupExtension me, IServiceProvider serviceProvider)
Exception Data : [EmptyOrNull]
Error 2
System.ComponentModel.Composition.CompositionException: The composition produced a single composition error. The root cause is provided below. Review the CompositionException.Errors property for more detailed information.
1) The current type, SquaredInfinity.Foundation.Configuration.Services.IConfigurationService, is an interface and cannot be constructed. Are you missing a type mapping?
Resulting in: Resolution of the dependency failed, type = "SquaredInfinity.Foundation.Configuration.Services.IConfigurationService", name = "(none)".
Exception occurred while: while resolving.
Exception is: InvalidOperationException - The current type, SquaredInfinity.Foundation.Configuration.Services.IConfigurationService, is an interface and cannot be constructed. Are you missing a type mapping?
-----------------------------------------------
At the time of the exception, the container was:
Resolving SquaredInfinity.Foundation.Configuration.Services.IConfigurationService,(none)
Resulting in: An exception occurred while trying to create an instance of type '#Btb.#Rtb'.
Resulting in: Cannot activate part '#Btb.#Rtb'.
Element: #Btb.#Rtb --> #Btb.#Rtb
Resulting in: Cannot get export '#Btb.#Rtb (ContractName="Microsoft.VisualStudio.Text.Classification.IClassifierProvider")' from part '#Btb.#Rtb'.
Element: #Btb.#Rtb (ContractName="Microsoft.VisualStudio.Text.Classification.IClassifierProvider") --> #Btb.#Rtb
at System.ComponentModel.Composition.Hosting.CompositionServices.GetExportedValueFromComposedPart(ImportEngine engine, ComposablePart part, ExportDefinition definition)
at System.ComponentModel.Composition.Hosting.CatalogExportProvider.GetExportedValue(CatalogPart part, ExportDefinition export, Boolean isSharedPart)
at System.ComponentModel.Composition.Hosting.CatalogExportProvider.CatalogExport.GetExportedValueCore()
at System.ComponentModel.Composition.Primitives.Export.get_Value()
at System.ComponentModel.Composition.ExportServices.GetCastedExportedValue[T](Export export)
at System.ComponentModel.Composition.ExportServices.<>c__DisplayClass4`2.<CreateStronglyTypedLazyOfTM>b__1()
at System.Lazy`1.CreateValue()
at System.Lazy`1.LazyInitValue()
at System.Lazy`1.get_Value()
at Microsoft.VisualStudio.Text.Utilities.GuardedOperations.InvokeMatchingFactories[TExtensionInstance,TExtensionFactory,TMetadataView](IEnumerable`1 lazyFactories, Func`2 getter, IContentType dataContentType, Object errorSource)
How do I interpret this so that I can figure out the error?
It seems there is something wrong with the VSCommands extension or another plugin. You can try to disable all extensions, restart Visual Studio and re-enable them; sometimes it resolves such issue.
Another thing you can try, is to run Visual Studio as administrator, because this error can occur if there are not sufficient permissions to access some resources (it was a bug in older releases of Visual Studio).
Your last painful resort will be a clean re-installation.
Just reinstall latest Web Essentials 5/5/2013. It resolves the problem. No need to uninstall or disable anything, just run setup again and you are done.
http://visualstudiogallery.msdn.microsoft.com/07d54d12-7133-4e15-becb-6f451ea3bea6
Fixed by deleting the following folder:
C:\Users{username}\AppData\Local\Microsoft\VisualStudio{version-number}\ComponentModelCache
This error starts after installing Visual Studio 2012 Update 2. Apparently the Web Tools and Web Essentials 2012 extensions have a conflict -- they both try to register some of the same components, which generates this exception.
Additionally, it appears the automatic update notification for one or both of these extensions is broken when VS 2012 Update 2 is installed, because though the extensions have been updated to resolve the conflict, you aren't notified that an update exists.
The solution is to remove both extensions, then reinstall them.
For more information about this, see http://madskristensen.net/post/web-tools-20122-and-web-essentials.
I was getting this same error. I noticed that the NuGet Package Manager extension had an update. After installing this update, the error went away.
Make sure all available updates are applied. To check if there are any updates available open Tools > Extensions and Updates. In the "Extensions and Updates" dialog, expand the "Updates" node in the left pane. Install any updates that may be available and restart Visual Studio 2012.
For all people having this problem:
Open Visual Studio 2012, but don't load any solutions / projects
Open Extensions and Updates from the Tools menu
Disable Web Essentials 2012
Delete the .suo file for your solution
Open the solution in Visual Studio
See that it loads and Visual Studio doesn't crash
Enable Web Essentials 2012
Restart Visual Studio 2012 and reload your solution.
Happy times!
Source
All you need to resolve the above stated issue is to delete the *.suo file for the project and Visual Studio. I had the same issue.
I was also getting the same error:
An exception has been encountered. This may be caused by an extension.
You can get more information by examining the file 'C:\Users\ . . .
\VisualStudio\11.0\ActivityLog.xml'
Reason:
I had uninstalled some of the SQL files from the control panel. Only after that did I start to get this error, but I was not sure which service I had uninstalled.
Solution:
I downloaded the SDK for Visual Studio 2012 and installed/restarted Visual Studio, then it worked fine.
error MSB4018: The "VCMessage" task failed unexpectedly.
System.FormatException: Index (zero based) must be greater than or equal to zero and less than the size of the argument list.
at System.Text.StringBuilder.AppendFormat(IFormatProvider provider, String format, Object[] args)
at System.String.Format(IFormatProvider provider, String format, Object[] args)
at Microsoft.Build.Shared.ResourceUtilities.FormatString(String unformatted, Object[] args)
at Microsoft.Build.Utilities.TaskLoggingHelper.FormatString(String unformatted, Object[] args)
at Microsoft.Build.Utilities.TaskLoggingHelper.FormatResourceString(String resourceName, Object[] args)
at Microsoft.Build.Utilities.TaskLoggingHelper.LogWarningWithCodeFromResources(String messageResourceName, Object[] messageArgs)
at Microsoft.Build.CPPTasks.VCMessage.Execute()
at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute()
at Microsoft.Build.BackEnd.TaskBuilder.ExecuteInstantiatedTask(ITaskExecutionHost taskExecutionHost, TaskLoggingContext taskLoggingContext, TaskHost taskHost, ItemBucket bucket, TaskExecutionMode howToExecuteTask, Boolean& taskResult) C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\Microsoft.CppBuild.targets 990 6 vtk_minimal
I had the same problem. I had an old Visual Studio 2005 C++ project, which I reopened with Visual Studio 2010 C++. For me, the first suggestion proposed at Microsoft Connect worked:
The issue stems from the unexpected $(TargetDir) found in the property page under Link->OutputFile. During the build process, we tried to expand the OutputFile to a fullpath but only got an empty value. Thus, it led to the index out-of-bound exception.
It is unlikely we will be able to fix these before VS2010 release. The workaround is to correct OutputPath or inherit from parent.
Right-click on the project and go to Properties > Linker > General. Then set "Output File" to "<Inherit from parent or project defaults>"
Hope that fixes it for you too.
I could not figure out what was wrong. The only thing that fixed this error for me was to remove the configuration and create a new one.
So in Configuration Manager I removed the one that would not build, and I recreated it from a similar one.
I have one web application made using MVC3 Razor.
Application starts properly in browser but after put some values in text box & click on search button I get error as
"The given key was not present in the dictionary".
This happens only in Windows server 2008 R2. In other Os like windows 7, Windows server 2008 sp1 it works fine.
Below is the Stack Trace
[KeyNotFoundException: The given key was not present in the dictionary.]
System.Collections.Generic.Dictionary`2.get_Item(TKey key) +12686831
CVR_Prototype.Controllers.HomeController.CvrDetailsCompleted() +171
lambda_method(Closure , ControllerBase , Object[] ) +79
System.Web.Mvc.Async.<>c__DisplayClass7.<BeginExecute>b__5(IAsyncResult asyncResult) +288
System.Web.Mvc.Async.<>c__DisplayClass41.<BeginInvokeAsynchronousActionMethod>b__40(IAsyncResult asyncResult) +22
System.Web.Mvc.Async.<>c__DisplayClass3b.<BeginInvokeActionMethodWithFilters>b__35() +129
System.Web.Mvc.Async.<>c__DisplayClass51.<InvokeActionMethodFilterAsynchronously>b__4b() +810887
System.Web.Mvc.Async.<>c__DisplayClass51.<InvokeActionMethodFilterAsynchronously>b__4b() +810887
System.Web.Mvc.Async.<>c__DisplayClass39.<BeginInvokeActionMethodWithFilters>b__38(IAsyncResult asyncResult) +15
System.Web.Mvc.Async.<>c__DisplayClass2c.<BeginInvokeAction>b__22() +33
System.Web.Mvc.Async.<>c__DisplayClass27.<BeginInvokeAction>b__24(IAsyncResult asyncResult) +811468
System.Web.Mvc.<>c__DisplayClass19.<BeginExecuteCore>b__14(IAsyncResult asyncResult) +28
System.Web.Mvc.Async.<>c__DisplayClass4.<MakeVoidDelegate>b__3(IAsyncResult ar) +20
System.Web.Mvc.AsyncController.EndExecuteCore(IAsyncResult asyncResult) +67
System.Web.Mvc.Async.<>c__DisplayClass4.<MakeVoidDelegate>b__3(IAsyncResult ar) +20
System.Web.Mvc.AsyncController.EndExecute(IAsyncResult asyncResult) +53
System.Web.Mvc.<>c__DisplayClassb.<BeginProcessRequest>b__4(IAsyncResult asyncResult) +42
System.Web.Mvc.Async.<>c__DisplayClass4.<MakeVoidDelegate>b__3(IAsyncResult ar) +20
System.Web.Mvc.<>c__DisplayClasse.<EndProcessRequest>b__d() +54
System.Web.CallHandlerExecutionStep.OnAsyncHandlerCompletion(IAsyncResult ar) +136
Source : http://shahvaibhav.com/solving-the-given-key-was-not-present-in-the-dictionary-error-of-visual-studio-2010/
While developing mvc3 razor application I came across one strange error “The given key was not present in the dictionary”.
After searching in google for hours I found the solution for this error.
Actually this error means that “This typically means that you’ve installed a custom data provider, created a Server Explorer connection using that provider, and then uninstalled the provider without deleting the Server Explorer entry”
To solve this error 1st thing you have to do is close all visual studio instances.
Now go to your user AppData directory (e.g. C:\Users\Administrator\AppData)
(Notice: AppData may not be shown in windows explorer if you have “Show hidden files and folders” turned off)
n AppData go to Roaming > Microsoft > Visual Studio > 10.0 > ServerExplorer
There you will find file named DefaultView.SEView. This files stores all connections.
This is a plain XML file, so in theory, you can locate the dud connection by its Label and just remove the containing DataViewNode XML element. In practice, I didn’t have much luck with this – the file stores blobs against connections by index, so deleting individual items can throw those indexes off. But if you’ve got a lot of connections defined and you don’t want to have to recreate them, it’s probably worth giving this a try in case you get luckier than I did.
Otherwise, just delete the DefaultView.SEView file.
Now restart visual studio & its done . Now you are free from that bad error.