This is a migrated thread and some comments may be shown as answers.

Setting the Visible Period For more Years (30-40Yrs) Not setting Properly

1 Answer 42 Views
TimeBar
This is a migrated thread and some comments may be shown as answers.
Balaji
Top achievements
Rank 1
Balaji asked on 29 Nov 2011, 02:48 AM

Hi ,

 

We are using the Rad Controls for Silver light Q1 2011 SP1 (Version 11.1.419.0) in our application.

 

In RADTimeBar , if we provide more years(30-40yrs eg.1980-2020) and setting the Visible period to certain Year (in design or runtime eg 1-Jan-2011 to 31-Dec-2011).

It is displaying extra year in the Display. (See the attachment pic).

 

Is it because of older version we are using?



Code :

<

 

 

UserControl.DataContext>

 

 

 

 

<example:ExampleViewModel StartDate="1-Jan-1980" EndDate="1-Jan-2020" />

 

 

 

 

</UserControl.DataContext>

 



<

 

 

Grid x:Name="LayoutRoot" Background="White">

 

 

 

 

<telerik:RadTimeBar x:Name="NotesHistoryRtb" Height="75" VerticalAlignment="Top" PeriodStart="1-Jan-1980" PeriodEnd="1-Jan-2020"

 

 

 

VisiblePeriodStart="1-Jan-2011" VisiblePeriodEnd="31-Dec-2011"

 

 

 

SelectionStart="1-Nov-2011" SelectionEnd="30-Nov-2011" BorderThickness="1,1,1,0" MaxSelectionRange="5" MinSelectionRange="1" Style="{StaticResource RadTimeBarStyle1}">

 

 

 

 

<telerik:RadTimeBar.Intervals>

 

 

 

 

<telerik:DecadeInterval/>

 

 

 

 

<telerik:YearInterval/>

 

 

 

 

<telerik:MonthInterval/>

 

 

 

 

<telerik:WeekInterval/>

 

 

 

 

<telerik:DayInterval/>

 

 

 

 

 

</telerik:RadTimeBar.Intervals>

 

 

 

 

<telerik:RadColumnSparkline Margin="0,3" ItemsSource="{Binding ColumnData}" XValuePath="Date" YValuePath="Value" ColumnWidthPercent=".8" Foreground="Red" />

 

 

 

 

</telerik:RadTimeBar>

 

 

 

 

</Grid>

 

1 Answer, 1 is accepted

Sort by
0
Tsvetie
Telerik team
answered on 29 Nov 2011, 09:26 AM
Hi Balaji,
No, this is not something specific to the version you use. This behavior will not change if you upgrade your version to the latest.

Due to a limitation in Silverlight framework, we have enforced a constraint for zoom-in to maximum of 30 000 pixels. As the period range of your timebar is large, when you try to zoom in to a single year, you hit the 30 000 pixel limit. The constraint is applied in both the Silverlight and WPF versions of the control and currently, there is no way to influence this, with the exception of modifying the source code, of course.

Best wishes,
Tsvetie
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

Tags
TimeBar
Asked by
Balaji
Top achievements
Rank 1
Answers by
Tsvetie
Telerik team
Share this question
or