Hi,
I am currently controlling the appearance of the timeline using the PrimaryInterval property. With the screen resolution I am constrained by and the interval set to 3 hours, I can display a whole day on the UI surface available to me.
To show more than a day I must set the interval to be less granular. Is there a way to control the number of intervals displayed, thereby retaining the granularity of a shorter interval by squashing them into a smaller space?
VisibleIntervals looked like it would give me what I want until I discovered that it's read only!
Regards, Jim.
Hristo / Roland,
Yes, this is what I was looking for.
ColumnWidth. Duh! How daft do I feel!!
Hello,
UltraTimeLineView has a property ColumnWidth which determines width of a column (time slot), if you change this property you could determine how many columns will be in view. I have created a sample to illustrates my idea. Please run the sample and let me know if this is what you are looking for, if this is not could you be more specific in description of your scenario.
Let me know if you have any further questions.
As far as I know you can ony approximate the displayed datetime range by adjusting the ColumnWidth based on the ClientSize and the number of primaryinterval units tou want to show.
This is what I do in the Resize:
double totalDays = (maxDate - minDate).TotalDays;Timeline.ColumnWidth = (int)Math.Round((Timeline.ClientSize.Width / totalDays) * 6.5);
Thanks for your response Hristo, but this is not what I'm trying to achieve.
The default logical day duration of 24 hours is fine for me as this is what we need to display.
What I would like to do is show a fixed timespan, be that 1 hour or 14 days, regardless of the primary interval. I suspect this is not possible but wanted to ask if there was anything I might try.
As far as I understand your issue you want to change logical day duration in order to display only worked hour in UltraTimeLineView. Is so you should set LogicalDayDuration to desired duration of UltraCalendarInfo associated with UltraTimeLineView or if you are not associate a CalendarInfo for the UltraTimelIneView to set this property to default one with code like:
ultraTimelineView1.CalendarInfo.LogicalDayDuration = new TimeSpan(12, 0, 0);
If you want to learn more about UltraCalendarInfo please look at the following link:
http://help.infragistics.com/NetAdvantage/WinForms/2010.2/CLR2.0/?page=WinCalendarInfo.html
let me know if you have any further questions.