Create a menu

2 posts, 0 answers
  1. Carlos
    Carlos avatar
    1 posts
    Member since:
    Dec 2012

    Posted 17 Dec 2012 Link to this post

    I'm trying to test the menu using the example code on the site, but I'm getting the following error:

    Value cannot be null.
    Parameter name: item

    Line 9:      <div id="IslandWebMenu">
    Line 10:         @(Html.Kendo().Menu()
    Line 11:             .Name("Menu")
    Line 12:             .Items(items =>

    Can, anyone, help me?

  2. Daniel
    Daniel avatar
    2110 posts

    Posted 19 Dec 2012 Link to this post

    Hello Carlos,

    This error could be thrown if the name is not specified. Since the Name method is used, the problem could be caused by not closing the explicit code nugget. The Menu should look similar to the one in the snippet below:

       .Items(items => {
           items.Add().Text("Home").Action("Index", "Home");
           items.Add().Text("About").Action("About", "Home");

    the Telerik team
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Back to Top