title: TreeView - Add nodes dynamically via client
body: <p>I'm just starting to use the Telerik asp.net mvc and I'm stuck on trying to add a node to the tree view via javascript... but I don't see anything in the documentation where this is possible. Anyone done this or maybe can point in the right direction where to find docs or examples?  </p>
  
  <p>Here is the code I used to setup the treeview: </p>
  
  <pre><code>@using (Html.BeginForm("Index", "Listings", FormMethod.Post, new { id = "frmListings", name = "frmListings" }))
      { 
          @(Html.Telerik().TreeView()
          .Name("topics")
          .ClientEvents(e =&gt; e.OnSelect("onSelect"))
          .BindTo(Model.Topics, mappings =&gt; mappings.For&lt;Topic&gt;(binding =&gt; binding
                                                  .ItemDataBound((item, category) =&gt;
                                                                  {
                                                                      item.Text = category.Name;
                                                                      item.Value = category.URI + "|" + category.Id.ToString();
                                                                      item.Selected = (Model.CurrentCategory.Id == category.Id);
                                                                      //item.Expanded = item.Selected;
                                                                  })
                                                  .Children(category =&gt; category.Children)
                                                ))
          )
  
      }
  </code></pre>