Wednesday, 18 December 2013

"The model item passed into the dictionary is of type 'System.Data.Entity.Infrastructure.DbQuery`1[System.Boolean]', but this dictionary requires a model item of type -" ASP.Net MVC


The model item passed into the dictionary is of type 'System.Data.Entity.Infrastructure.DbQuery`1[System.Boolean]', but this dictionary requires a model item of type

 

This error would appear when the Controller return the result which is not of type that View is expecting if your view is tightly bound with the model.

Also note that whether you returning a single item of object or returning a collection, even though you return the same object if it is a collection then it would throw back this error.

 

No comments:

Post a Comment