Back to Devexpress

TasksScheduledEventArgs.InvalidPredecessorLinks Property

wpf-devexpress-dot-xpf-dot-gantt-dot-tasksscheduledeventargs.md

latest2.6 KB
Original Source

TasksScheduledEventArgs.InvalidPredecessorLinks Property

Gets a collection of predecessor links that are invalid after scheduling.

Namespace : DevExpress.Xpf.Gantt

Assembly : DevExpress.Xpf.Gantt.v25.2.dll

NuGet Package : DevExpress.Wpf.Gantt

Declaration

csharp
public ReadOnlyCollection<object> InvalidPredecessorLinks { get; }
vb
Public ReadOnly Property InvalidPredecessorLinks As ReadOnlyCollection(Of Object)

Property Value

TypeDescription
ReadOnlyCollection<Object>

A collection of invalid predecessor links.

|

Remarks

The InvalidPredecessorLinks property does not return any invalid links if the link validation is disabled (the AllowValidatePredecessorLinks is set to false ).

You can rollback the edit changes if they have become the reason for invalid links.

xaml
<dxgn:GanttControl ...>
    <dxgn:GanttControl.View>
        <dxgn:GanttView ... 
            TasksScheduled="GanttView_TasksScheduled">
        </dxgn:GanttView>
    </dxgn:GanttControl.View>
</dxgn:GanttControl>
csharp
private void GanttView_TasksScheduled(object sender, DevExpress.Xpf.Gantt.TasksScheduledEventArgs e) {
    if (e.InvalidPredecessorLinks.Count > 0) e.RollbackChanges = true;
}
vb
Private Sub GanttView_TasksScheduled(ByVal sender As Object, ByVal e As DevExpress.Xpf.Gantt.TasksScheduledEventArgs)
    If e.InvalidPredecessorLinks.Count > 0 Then e.RollbackChanges = True
End Sub

See Also

AllowValidatePredecessorLinks

TasksScheduledEventArgs Class

TasksScheduledEventArgs Members

DevExpress.Xpf.Gantt Namespace