Back to Devexpress

GanttView.StripLines Property

wpf-devexpress-dot-xpf-dot-gantt-dot-ganttview-bddafd02.md

latest2.4 KB
Original Source

GanttView.StripLines Property

Provides access to a collection of strip lines displayed within the Gantt area. This is a dependency property.

Namespace : DevExpress.Xpf.Gantt

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

NuGet Package : DevExpress.Wpf.Gantt

Declaration

csharp
public StripLineCollection StripLines { get; }
vb
Public ReadOnly Property StripLines As StripLineCollection

Property Value

TypeDescription
StripLineCollection

A collection of strip lines.

|

Remarks

The GanttControl stores its strip lines within the StripLines collection. This collection provides methods that allow you to add new and remove existing strip lines. Individual strip lines are represented by StripLineBase class descendants.

Example

Use the GanttView.StripLines property to populate a collection of strip lines displayed within the Gantt area.

xaml
<Window ...
    xmlns:dxgn="http://schemas.devexpress.com/winfx/2008/xaml/gantt" />

<dxgn:GanttControl ItemsSource="{Binding Tasks}" >
    <dxgn:GanttControl.View>
        <dxgn:GanttView
            x:Name="view" ... >
            <dxgn:GanttView.StripLines>
                <dxgn:CurrentDateTimeStripLine />
                <dxgn:StripLine StartDate="08/14/2019 10:00:00" Duration="5:0:0" Background="#3FF5BD53"/>
                <dxgn:StripLineRule
                    Recurrence="{dxgn:Weekly DayOfWeek=Friday, Start=1/1/2019, Until=9/1/2019}"
                    StartOffset="8:0:0"
                    Duration="8:0:0" />
            </dxgn:GanttView.StripLines>
        </dxgn:GanttView>
    </dxgn:GanttControl.View>
</dxgn:GanttControl>
</Window>

See Also

GanttView Class

GanttView Members

DevExpress.Xpf.Gantt Namespace