To create an editable chart, you should call setEditable(true) method in your initialization code. Then user can edit your chart in many ways - create new tasks, delete, modify task duration, percent complete etc. using his mouse or thru the tree menu.
You may use the built-in tree menu, which is enabled by showContextMenu(true), or you may use your own menu control.
It is also useful to use showNewProject(true) method if you plan for your user to start a completely new project from scratch. In this case we will create a new project record by default and user will be able to add tasks etc.
<div style="width:950px;height:620px;position:absolute" id="GanttDiv"></div> <script> var gantt = new GanttChart(); gantt.setImagePath("imgs/"); gantt.setEditable(true); gantt.create("GanttDiv"); gantt.loadData("data/chart1.xml",true,true); </script>