Incorrect VisiblePeriodStart and VisiblePeriodEnd displayed on timeline when bound

5 posts, 0 answers
  1. MARTIN
    MARTIN avatar
    7 posts
    Member since:
    Jul 2013

    Posted 17 Nov 2014 Link to this post

    Hi

    I am currently having some issues with the RadTimeline control. Currently I have a RadTimeline whose VisiblePeriodStart and VisiblePeriodEnd properties are two way bound to my ViewModel. We have a Listbox control that the user can select Day/Week/Month/Year views and the ViewModel updates the visible period properties accordingly. I am encountering problems with a discrepancy between the value of the bound properties and what it actually displayed on the timeline.

    The default view shows from the 1/1/2014 to now and looks something like this. After selecting Week view the start and end properties are set to 1/1/2014 and 8/1/2014 respectively. This time period is not what is shown on the timeline, instead the timeline appears like this. As you can see this is roughly a 2.5 week period. Adding a handler to the VisiblePeriodChanged event shows this problem clearly. Here is a screen capture of the handler method after the week view change. As you can see the bound property has a value different to what timeline control's visible end is.

    Could this be a problem with the control not properly scaling down from large to smaller time periods?

    This is a very important feature for us so a speedy reply would be appreciated. Thanks!
  2. Tsvetie
    Admin
    Tsvetie avatar
    1517 posts

    Posted 19 Nov 2014 Link to this post

    Hi Martin,

    As I do not have your code, I cannot be sure what could be causing the problem. That is why, in case the information below does not help you, I would suggest that you open a support ticket and send us a simple running project, demonstrating the problem.

    Now, this can happen when the control hits is MinZoomRange default value. By default, the control allows zooming in to a certain minimum range. If this is the case, you can set a value to this property that matches your expectations and the control will respect it.

    Regards,
    Tsvetie
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
  3. UI for WPF is Visual Studio 2017 Ready
  4. MARTIN
    MARTIN avatar
    7 posts
    Member since:
    Jul 2013

    Posted 19 Nov 2014 in reply to Tsvetie Link to this post

    Hi Tsvetie

    Setting the MinZoomRange to a small value did indeed solve this problem.

    I find the behaviour of this property a bit strange given that the timeline can be zoomed past this value using the horizontal scrollbar. Yet when the visible range is bound to properties it does not zoom past the MinZoomRange value. I think the MinZoomRange should also be observed by the horizontal scrollbar for consistency.

    Thanks for the help!
  5. Tsvetie
    Admin
    Tsvetie avatar
    1517 posts

    Posted 20 Nov 2014 Link to this post

    Hello Martin,

    Yes, you are correct and this should be the case. I am not sure why you get different result with the scrollBar and the mouse wheel. In case you send a test project, I can check what is causing this problem.

    Regards,
    Tsvetie
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
  6. MARTIN
    MARTIN avatar
    7 posts
    Member since:
    Jul 2013

    Posted 20 Nov 2014 in reply to Tsvetie Link to this post

    Hi Tsvetie

    I have not been able to reproduce this inconsistent behaviour in a test project. The issue must be specific to our project.

    Thank you for your help
Back to Top
UI for WPF is Visual Studio 2017 Ready