$(document).ready(function () { $("#navigation").treeview({ persist: "location", collapsed: true, animated: "medium", control: "#treecontrol", toggle: function () { var swimlaneId = this.id.replace('listSwimlane', 'ulActivity'); $.ajax({ type: "POST", url: "Test.aspx?Action=load&SwimlaneID=5", // data: "{}", contentType: "application/json; charset=utf-8", dataType: "html", success: function (msg) { alert(msg); $("#" + swimlaneId).html(msg); }, error: function (msg) { alert(msg.d); } }); // $("#" + this.id.replace('listSwimlane', 'ulActivity')).load("Test.aspx?SwimlaneID=1 #divActivities"); } });
toggle: function () { // if tree branch is expandable only, the below method can work. if (this.className.indexOf('collapsable') >= 0) { //some code here }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)