Scroll View with data template

3 posts, 0 answers
  1. David
    David avatar
    60 posts
    Member since:
    Nov 2012

    Posted 09 Jul 2013 Link to this post

    I am trying to use a template to render pages in a scroll view and I have run into some issues ...  I have a jsFiddle that shows what I am trying to do the group has a red header with 'why does this not work'.  I have a bunch of examples of things using templates and I don't understand why the template with the scroll view does not behave like the rest, could someone explain what I am missing?

    http://jsfiddle.net/6RuHQ/6/

    In case you are curious I am probably going to wind up with the last approach with my application since in some occasions I will end up with only 1 page and it looks silly as a scroller with 1 page (I'd rather just render that single page by itself).
  2. David
    David avatar
    60 posts
    Member since:
    Nov 2012

    Posted 09 Jul 2013 Link to this post

    I did some fooling around with data source binding with templates to get something similar working, and came across something that seems to be behaving strangely.

    Could you explain why in this fiddle (http://jsfiddle.net/2PTLE/1/) that pressing the 'change Dummy' button causes the template to not appear properly any longer?

    I don't understand why the template would render fine once but then improperly afterwards ...

    I realize I may be trying to do something advanced but I need the contents of a scroller to change based on an item that is currently selected (the selected item may have an array of dataobjects that need to be displayed on seperate pages).  I can brute force this and code it all in javascript if I need to but that is not appealing.
  3. Kendo UI is VS 2017 Ready
  4. Petyo
    Admin
    Petyo avatar
    2439 posts

    Posted 10 Jul 2013 Link to this post

    Hello David,

    The scrollview is somewhat sensitive to dimensions change. By default, it sets its dimensions when the containing view is displayed. In your case, you will have to call the refresh method manually. Please see the updated example for what I mean.

    Regards,
    Petyo
    Telerik
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Back to Top