Here is the problem. I am getting IEnumerable from ViewPage and when I tried it to convert List it is showing me error like:
\'System.Collection
System.Collection
In my case, I had copied some code from another project that was using Automapper - took me ages to work that one out. Just had to add automapper nuget package to project.