Prevent expansion

Is it possible to prevent to user to expand the Task from left and allow it from right?

Best Regards
Gian Piero Truccolo

3 Replies 1 reply marked as answer

SS Sridevi Sivakumar Syncfusion Team March 8, 2021 01:08 PM UTC

Hi Gian Piero Truccolo,

Greetings from Syncfusion.

We have validated your query, and we would like to inform you that we don't have direct support for this requirement. So currently, we are checking possible solution for this and we will update the details on Mar 10, 2021.

Let us know if you need any further assistance.

Regards,
Sridevi S.
 



GI Gian March 8, 2021 01:46 PM UTC

Hi.Sridevi,

thanks for te answer in order to be more clear in my request i add also an image.



I ask you to keep me inform regarding this features.

Best regards
Gian Piero Truccolo


SS Sridevi Sivakumar Syncfusion Team March 9, 2021 11:35 AM UTC

Hi Gian Piero Truccolo,

Thanks for your update.

We have analyzed your requirement and we can restrict the left thumb click action by setting the IsHitTestVisible false to the left thumb in the GanttNode Template.

Code snippet[XAML]: 
<Window.Resources> 
       ... 
        <Style TargetType="chart:GanttNode" x:Key="TaskNode"> 
            <Setter Property="HorizontalAlignment" 
                    Value="Left" /> 
            <Setter Property="Template"> 
                <Setter.Value> 
                    <ControlTemplate TargetType="chart:GanttNode"> 
     ... 
                                    <Thumb Cursor="ScrollW" 
                                           MaxWidth="6" 
                                           Grid.Column="0" 
                                           HorizontalAlignment="left" 
                                           x:Name="PART_LeftThumb" 
                                           IsHitTestVisible="False" 
                                           SnapsToDevicePixels="True"> 
 ... 
                    </ControlTemplate> 
                </Setter.Value> 
            </Setter> 
        </Style> 
    </Window.Resources>

 <Grid>
 
        <!--  Gantt Control Information  --> 
        <gantt:GanttControl x:Name="Gantt" 
                            ItemsSource="{Binding TaskDetails}"> 
        ... 
            <gantt:GanttControl.Resources> 
                <Style TargetType="chart:GanttNode" 
                       BasedOn="{StaticResource TaskNode}" /> 
            </gantt:GanttControl.Resources> 
        </gantt:GanttControl> 
    </Grid> 

We have prepared a sample based on this, please find the sample from the following location.
https://www.syncfusion.com/downloads/support/directtrac/general/ze/GanttControl_Sample-1597787133

Let us know if you need any further assistance.

Regards,
Sridevi S.
 
  
 


Marked as answer
Loader.
Up arrow icon