The model being passed to my view is of type tblUser
- so I expected that I would be able to:
<% Model.tblLogins.Where(l => l.date > DateTime.Now.AddDays(-7)).Count() %>
However, the .Where()
part is not available as an option? I have the following in my web.config
but hasnt helped:
<add namespace="System.Linq"/>
<add namespace="System.Data.Linq"/>
<add namespace="System.Collections.Generic"/>
Has anyone had this problem before? Thanks for any assistance :)