Version

Add Numeric Event Entries

An event entry is the data point for a time series in xamTimeline™. It provides information such as Time, Title, Duration, and Details that is associated with each event. There are two types of event entries: a NumericTimeEntry for the NumericTimeSeries object, and a DateTimeEntry for the DateTimeSeries object.

Note
Note:

For more information on the different types of time series, see Time Series.

This example assumes that you know how to setup your project for Infragistics XamTimeline control. The following xaml code shows how to add numeric time entries to a Numeric Time Series.

In XAML:

<ig:XamTimeline x:Name="Timeline"
                Width="1000" Height="400" Margin="15">
    <ig:XamTimeline.Series>
        <ig:NumericTimeSeries Title="xaml Series">
            <ig:NumericTimeSeries.Entries>
                <!-- Add Numeric Time Entries  -->
                <ig:NumericTimeEntry Time="500" Title="Numeric Time Entry 1"
                                       Details="Details Time Entry 1"/>
                <ig:NumericTimeEntry Time="1000" Title="Numeric Time Entry 2"
                                       Details="Details Time Entry 2"/>
                <ig:NumericTimeEntry Time="1500" Title="Numeric Time Entry 3"
                                       Details="Details Time Entry 3"/>
                <ig:NumericTimeEntry Time="2000" Title="Numeric Time Entry 4"
                                       Details="Details Time Entry 4"/>
                <ig:NumericTimeEntry Time="2500" Title="Numeric Time Entry 5"
                                       Details="Details Time Entry 5"/>
            </ig:NumericTimeSeries.Entries>
        </ig:NumericTimeSeries>
    </ig:XamTimeline.Series>
</ig:XamTimeline>

In Visual Basic:

Dim Timeline As New XamTimeline()
Me.LayoutRoot.Children.Add(Timeline)
'Add Numeric Time Entries
Dim numTimeSeries As New NumericTimeSeries()
For ind As Integer = 1 To 5
    Dim entry As New NumericTimeEntry()
    entry.Time = ind * 500
    entry.Title = "Numeric Time Entry " + ind.ToString()
    entry.Details = "Details Time Entry " + ind.ToString()
    numTimeSeries.Entries.Add(entry)
Next
Me.Timeline.Series.Add(numTimeSeries)

In C#:

var Timeline = new XamTimeline();
this.LayoutRoot.Children.Add(Timeline);
// Add Numeric Time Entries
var numTimeSeries = new NumericTimeSeries();
for (int ind = 1; ind <= 5 ind++)
{
    var entry = new NumericTimeEntry();
    entry.Time = ind * 500;
    entry.Title = "Numeric Time Entry " + ind.ToString();
    entry.Details = "Details Time Entry " + ind.ToString();
    numTimeSeries.Entries.Add(entry);
}
Timeline.Series.Add(numTimeSeries);
XamTimeline Add Event Entries 01.png