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

How to disable the resizing and the drag and drop of appointments


I am working with a GanttControl with an item datasource, so I don´t want to be able to move and resize appointments. How can i do it? 

Thanks in advance.

5 Replies

MK Muneesh Kumar G Syncfusion Team April 15, 2019 06:46 AM

Hi Ander, 
Greetings from Syncfusion,  
We have analyzed your requirement and you can achieve this by disabling the GanttChart as per the below code snippet. 

<!--  Gantt Control Information  --> 
<gantt:GanttControl x:Name="Gantt" 
                    ItemsSource="{Binding TaskDetails}" 
private void Gantt_OnLoaded(object sender, RoutedEventArgs e) 
    GanttChart chart = this.Gantt.FindElementOfType<GanttChart>(); 
    if (chart != null) 
        chart.IsEnabled = false; 
We have prepared a sample based on this, please find the sample from the following location.  
Hope it helps you.  
Muneesh Kumar G. 

AC Ander Caloca April 15, 2019 07:04 AM

Hi Muneesh,

I implement the code that you pass and the drag, drop and resize works perfectly, but with the property isenabled as false i am not able to see the tooltip information. Can I disable the drag,drop,resize properties but not the tooltip?

MK Muneesh Kumar G Syncfusion Team April 16, 2019 02:27 AM

Hi Ander, 
Thanks for you update. 
We have achieved your requirement by applying custom node style (removed the touch points & disabled the dragging and resizing thumbs in the default node style) as per the below snippet 
Code snippet: 
<!--  GanttControl Information  --> 
<sync:GanttControl x:Name="Gantt" 
        <Style BasedOn="{StaticResource HeaderNode}" TargetType="chart:HeaderNode" /> 
        <Style BasedOn="{StaticResource TaskNode}" TargetType="chart:GanttNode" /> 
        <Style BasedOn="{StaticResource MileStone}" TargetType="chart:MileStone" /> 
Please find the sample from the below link. 
To know more about custom node style. Please refer the following user guide link. 
Please let us know if you have any other queries. 
Muneesh Kumar G. 

AC Ander Caloca April 16, 2019 03:29 AM

Hi Muneesh,

Thank you for your answer and attention. Now it works perfectly.


MK Muneesh Kumar G Syncfusion Team April 16, 2019 03:47 AM

Hi Ander,  
Glad that the requirement has been achieved and please get back to us if you need any other assistance. 
Muneesh Kumar G. 

Live Chat Icon For mobile
Up arrow icon