View Single Post
  #2 (permalink)  
Old July 10th, 2010, 05:04 AM
fh84 fh84 is offline
Authorized User
 
Join Date: Dec 2008
Location: , , Greece.
Posts: 56
Thanks: 1
Thanked 1 Time in 1 Post
Send a message via MSN to fh84
Default

Hello again,
Well I was looking around on the code and I found out that there are 2 errors in the page under ~/views/article/Index.aspx

Both errors say that Error The type or namespace name 'Article + Category' could not be found (are you missing a using directive or an assembly reference?)

I am sure i am missing something but i cannot find what!

please help

Code:
<% foreach(Article article in ViewData.Model) { %>
    <% Html.RenderPartial("~/Views/Shared/Article/ArticleItem.ascx", article); %>
    <hr />
<% } %>
</div>

<% Html.RenderPartial("~/Views/Shared/Pager.ascx", ViewData.Model); %>
</asp:Content>

<asp:Content ID="SidebarContent" ContentPlaceHolderID="SidebarContent" runat="server">
        <div id="news" class="boxed">
            <h2 class="title">Categories</h2>
            <div class="content">
                <ul>
                    <li class="first"><a href="/">All</a></li>
    <% foreach(var category in ViewData["Categories"] as IEnumerable<Category>) { %>
                    <li><%= Html.ActionLink(category.Title, "Index", new { controller = "Article", category = category.Path })%></li>
    <% } %>
                </ul>
            </div>
        </div>