Question

I'm using the Ninject.MVC3 in my application and it has been working great until I desided to rename my solution/projects. Everything has been renamed correctly and all tests passes and so on. The one thing that does not work is the generated NinjectWebCommon class.

This line:

bootstrapper.Initialize(CreateKernel);

Throws this exception:

System.InvalidOperationException: Sequence contains no elements

When I look at the "yellow screen of death" I see that the source file of NinjectWebCommon.cs is totally wrong. It's the path that was accurate before the projects got renamed.

I've checked all paths in the .proj files and can't find any error there. I've also tried to throw away the app_start folder and re-installing the nuget packages.

Any suggestions.

Was it helpful?

Solution

Finally solved this one by clearing the web site cache:

%LocalAppData%\Microsoft\WebsiteCache

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top