Data attribute initialization

3 posts, 1 answers
  1. RES
    RES avatar
    77 posts
    Member since:
    Sep 2010

    Posted 05 May 2014 Link to this post

    I'd like to set the following Grid property via data attribute initialization.

    So I've added the following attribute but it doesn't seem to work.

    data-pageable="messages: { display: 'Showing {0}-{1} of {2} leads' }"

    Is it possible to set this property via attributes?
  2. Answer
    Rosen avatar
    3215 posts

    Posted 07 May 2014 Link to this post


    I'm afraid that I'm unable to observe such behavior locally. Please take a look at the following test page. Maybe I'm missing something obvious.

    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  3. RES
    RES avatar
    77 posts
    Member since:
    Sep 2010

    Posted 07 May 2014 in reply to Rosen Link to this post

    Ahh good example.  You have your attribute value wrapped in curly brackets like this.

    data-pageable="{messages:{display:'Showing {0}-{1} of {2} leads' }}"

    Where as I have mine without the outer curly brackets.

    data-pageable="messages:{display:'Showing {0}-{1} of {2} leads' }"

    This fixes my problem, thanks.
Back to Top