We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

Gantt predecessor validation issues


I encountered a strange behavior in the Gantt chart when enablePredecessorValidation={false} and  isInPredecessorValidation = true in the taskbarEditingEvent. For some reason, after the Gantt is loaded and filled in with data, when I move a milestone from the top of the tasks list.. the Gantt is triggering PredecessorValidation and ruins the entire scheduling of the tasks.

In our usage, we have mostly milestones in the tasks list. When the predecessor validation is happening, all the milestones happen in the same day because there is no duration.

After some research, I found out that we can disable the predecessor validation and rely on the dependency + offset to display the milestones in time like the project manager wants. So this was fixed by  enablePredecessorValidation={false}. 

The second issue was that the data was loading fine, displaying the milestones with offsets but there was no longer any dependency happening, meaning that if I moved a milestone, the rest were not moving. In order to fix this I added in the taskbarEditingEvent the parameter isInPredecessorValidation = true as I found out in this forum.

So now everything is working as expected except the first interaction with the Gantt after the data is loaded. Moving the first milestone, will reset everything and afterwards everything seem to work as expected, so only in the first interaction this is happening and I don't know why.

I prepared an example:


If you move (via drag and drop) the milestone  Project start - comissioning .. by one day, then everything is reset..

Is there a way to fix this?

5 Replies 1 reply marked as answer

GM Gopinath Munusamy Syncfusion Team October 28, 2022 05:26 AM

Hi Mircea Catalin,

Greetings from Syncfusion support.

We have checked you query but the details you have shared is not much enough to understand the exact requirement. Whether you want to restrict the predecessor validation between the tasks then you can leave the default value of isInPredecessorValidation as false inside the taskbarEditingEvent. If you change the isInPredecessorValidation equal to true then the predecessor validation should be performed, based on that the dates should be changes as per the validation, which is the default behavior. So, we request you to share below details, which will be useful for us to provide you with a better solution.

  1. Can you please explain the exact requirement?
  2. Video demonstration of the issue.
  3. Whether you want to perform the predecessor validation for that particular dragged task?  


Gopinath M

MC Mircea Catalin replied to Gopinath Munusamy October 28, 2022 08:53 AM

Hi Gopinath M,

  1. The data is loaded into the gantt chart with offsets between milestones. I expect that if I move the first milestone in the list, the other milestones should move and maintain the offset. I do NOT expect that all the offsets get reset if I move the top milestones.
  2. Attached video
  3. I don't think I understand correctly how the predecessor validation works. When we start with a fresh project, all the milestones have the same date. Then we start to set them up from the top and go down, moving milestones. When the data gets saved into the database, we save also the dependencies with the offsets. So, the end result is looking like in the video. But once you refresh the page and the data is loaded from the DB and we need to change something from the top, then it's resetting all the offsets from that point down, instead of moving all the milestones maintaining the offsets.

Attachment: 20221028_163217_e3e1b2a1.zip

GM Gopinath Munusamy Syncfusion Team November 1, 2022 07:12 AM

Hi Mircea Catalin,

Thanks for sharing the video.

We would like to inform you that the dependency is the relationship between predecessor and successor tasks. The predecessor is the first task which controls the start or end date for all related successor tasks. The successorby contrast, is the task whose start or end date is controlled by the predecessor. In your sample you have used the cascade dependencies functionality, whenever you have modified a Start and/or End date for the predecessor task, the changes automatically roll down to dependent tasks(successor tasks), which results in predecessor validation for all connected successor task and change the start date of all successor task, but it should not affect the start or end date of any related predecessor task, which is not an issue and it is the default behavior in Task Dependency.

We have attached a Video demonstration for your reference. In this demo, you can see that when you moved a task, only the start date and end date for all connected successor tasks is changed, and this should not affect the start date and end date of any predecessor task. Please check this below video demonstration for more details,

Video Demonstration: https://www.syncfusion.com/downloads/support/forum/178466/ze/Predecessor_offset849680667.zip


Gopinath M

Marked as answer

MC Mircea Catalin November 1, 2022 10:48 AM

Hi Gopinath M,

Ohhhh, now I realized why it was not working for me as expected. How embarrassing.. I was saving the offsets into the DB but forgot to update some code that was retrieving the data on the predecessor column. I have a piece of code that if the predecessor is null, then it computes it.. but without offset.

So, basically my data does not contain the offsets. I got mislead by the fact that even without the offsets the milestones were in the correct spot because of the start and end dates..

I noticed this mistake by looking at your video when you show the offsets, I then looked at mine...and all my data had missing offsets.

I updated my code and everything is working as expected.

Many thanks for your explanation and video!



GM Gopinath Munusamy Syncfusion Team November 2, 2022 04:19 AM

Hi Mircea,

You’re most welcome.

We are glad to know that the reported problem has been resolved at your end. Please get back to us if you require any further assistance on this.


Gopinath M

Live Chat Icon For mobile
Up arrow icon