I am adding a PagedList to my view and loosely following this Tutorial. I have installed the PagedList reference using Nuget, set up my controller as follows
Something is messed up with my overall project. I created a new project and copied the important items over and it all works now. I am not sure at all what is wrong with my original project.
First sorry for my terrible English. In my case, I use the MVC5 in Visual Studio Community 2015 and I solved the problem this way:
First I delete the cache of Visual Studio and NuGet cache:
After I use the package manager console to remove PagedList.MVC, then remove PagedList and then re-install them again like so:
I holpe that help
I needed to add the namespace to the Views web.config file.
Details are in this SO post:
I then needed to close/re-open Visual Studio 2010 in order for it to recognize. Compiling the project didn't help (the web.config might only be read once upon project load).