Apr 30, 2012 at 5:16 PM
Edited Apr 30, 2012 at 5:56 PM
|
Hello,
I am using this timeline control in my WPF application. The issue I am facing is that if I add 2 events starting on same date, they get added to the canvas on same spot and are stacked over each other making it impossible to see both. Is there a way these
can be automatically arranged vertically when adding events with same start date?
I tried RowOverride property but it seems I can get only 2 events working that way. If I try adding 3 or more events ..I can see only 2 events...here is the code I am using to add events. Here I can see only Green and Red event but dont see the last one
(Blue):
public TimeLineModelView()
{
List<TimelineLibrary.TimelineEvent> events = new List<TimelineLibrary.TimelineEvent>();
TimelineLibrary.TimelineEvent ev = new TimelineLibrary.TimelineEvent()
{
Description = "Stand Activity for stand a",
EndDate = DateTime.Parse("1/1/2013"),
StartDate = DateTime.Today,
Title = "Stand A Activity",
EventColor = "Red",
RowOverride = 0,
TopOverride=0
};
events.Add(ev);
events.Add(new TimelineLibrary.TimelineEvent()
{
Description = "Stand Activity for stand b",
EndDate = DateTime.Parse("2/1/2013"),
StartDate = DateTime.Today,
Title = "Stand B Activity",
EventColor = "Green",
RowOverride=1,
TopOverride = 1
});
events.Add(new TimelineLibrary.TimelineEvent()
{
Description = "Stand Activity for stand c",
EndDate = DateTime.Parse("2/1/2013"),
StartDate = DateTime.Today,
Title = "Stand C Activity",
EventColor = "Blue",
RowOverride=2,
TopOverride = 2
});
Events = events;
}
Thanks
Apurva
|
|
Coordinator
May 1, 2012 at 4:53 AM
|
Do not use TopOverride. Also you can specify lower row TimelineBand.MaxEventHeight. Yet you can try to use TimelineTrayEx instead of TimelineTray, which supports scrollbar.
Let me know.
|
|
|
|
Yes I tried specifying a lower value for TimelineBand.MaxEventHeight in XAML and it seems to work! Thanks!
|
|