This is a migrated thread and some comments may be shown as answers.

How to Reload whole Gantt After Insert and Update

3 Answers 713 Views
Gantt
This is a migrated thread and some comments may be shown as answers.
ram
Top achievements
Rank 1
ram asked on 18 Nov 2014, 01:51 PM
Hi Team,

       I have Two Issues..
      1 )     How to Reload whole Gantt  After Insert and Update .. By default it  refresh only inserted  and updated row . I need to update All the rows for some) condition and refresh the gantt after insert and upload.. 
          
      2)    Move,MoveStart, MoveEnd Events are not Triggered while dragging the row..

Thank You ..

3 Answers, 1 is accepted

Sort by
0
T. Tsonev
Telerik team
answered on 20 Nov 2014, 03:39 PM
Hello,

The Gantt can be forced to do a full refresh by calling the read method on its data sources:
<script>
  var gantt = $("#gantt").getKendoGantt();
  gantt.dataSource.read()
  gantt.dependencies.read()
</script>


I'm not sure what do you mean by the row in the second question.
Dragging the tasks will trigger these events as in the demo.

Reordering the tasks from the list on the left will not trigger these events.
This is by design and the model will updated as a result of the reordering.

I hope this helps.

Regards,
T. Tsonev
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
ram
Top achievements
Rank 1
answered on 24 Nov 2014, 09:49 AM
Hi T.Tsonev,
            I have Already tried the Above code in Add Event. But It gets Refresh before the Value Added to gantt . I need to refresh Whole Gantt After the Value Binded to Gantt.
            Actually My Requirement is To Update all Values in a One Column based on Where I Insert and Update ..
0
Kiril Nikolov
Telerik team
answered on 26 Nov 2014, 01:23 PM
Hello Ram,

One solution is to add setTimeout() function in your add event and execute the code inside, so you will make sure that the Gantt is refreshed after the record is added. However I am not really sure why you need to refresh the Gantt, as adding a new records will automatically refresh the Gantt and fire the dataBound event. Can you please clarify this a little bit? Can you provide a sample code of what exactly you are trying to achieve?

Regards,
Kiril Nikolov
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
Tags
Gantt
Asked by
ram
Top achievements
Rank 1
Answers by
T. Tsonev
Telerik team
ram
Top achievements
Rank 1
Kiril Nikolov
Telerik team
Share this question
or