Repeat header for every set of rows

7 posts, 0 answers
  1. Wadigzon
    Wadigzon avatar
    58 posts
    Member since:
    Feb 2013

    Posted 22 May 2013 Link to this post

    Hello there,

    I tried using a list putting the headers on list1 and the data on list2
    and creating column/row groupings for each list, but did not work as I have only one header per group, 
    I ended up having a bunch of headers at the beginning,
    This is my data structure: {id, description}

    so my data can be :
    {1, "first record"}, 
    {2, "second record"}
    ...
    {32, "thirty second record"}

    This is what I'd like to accomplish
    Identifier Description
    =======================
    1 first record
    2 second record
    3 third record
    4 fourth record

    Identifier Description
    =======================
    5 fifth record
    6 sixth record
    7 seventh record
    8 eighth record

    ... ...

    Identifier Description
    =======================
    29 twenty ninth record
    30 thirtieth record
    31 thirty first record
    32 thirty second record

    Hope you can help. 
  2. Gimmik
    Gimmik avatar
    170 posts
    Member since:
    May 2011

    Posted 23 May 2013 Link to this post

    Hi Wadigzon,

    Assuming the breaks in your data-layout are page breaks, just put some TextBox Items in the Page Header section and put static text in them. They'll print at the top of each page. Assuming they are Grouping-breaks, follow the same logic but place in the the Group Header. In the Details section you'll place two TextBox Items with expressions in them. They'll look something like this, but will depend on your field names.
    =Fields.id
    =Fields.description
  3. DevCraft banner
  4. Wadigzon
    Wadigzon avatar
    58 posts
    Member since:
    Feb 2013

    Posted 23 May 2013 Link to this post

    GimmikThey are not page breaks, the question is very simple: How do I put header titles every n-th row, for my sample data n was equal to four.

    I did not see number four in your answer. 

    regards,
  5. Wadigzon
    Wadigzon avatar
    58 posts
    Member since:
    Feb 2013

    Posted 23 May 2013 Link to this post

    I got it figured it out, in the sample image n=8
    you need to add a grouping with the following expression "Fields.Id/8"

    that would have helped a lot.

    thanks 
  6. Gimmik
    Gimmik avatar
    170 posts
    Member since:
    May 2011

    Posted 23 May 2013 Link to this post

    Hi Wadigzon,

    I'm glad you figured it out. You can definitely use that expression to group your data. Just keep in mind that the expression will only group as you expect, providing your ID field is continuous, uninterrupted, and sorted. To understand what I mean - take a look at the screen shot below of a report generated from AdventureWorks.

    If you delete your 2nd, 3rd, and 4th record, you'll only have 5 items in your first group.

    One trick is to include a hidden field in your data such as RowNumber() in SQL, that way you always have a reliable field to group-by. That's what I did.
  7. Wadigzon
    Wadigzon avatar
    58 posts
    Member since:
    Feb 2013

    Posted 24 Jul 2013 Link to this post

    Gimmik,
    Is there any way to do this in a list? I don't want to break this into many pages when I am doing the HTML review I posted this request at another thread: http://www.telerik.com/community/forums/reporting/telerik-reporting/special-grouping-in-a-list-needed.aspx

    The reason I want a list, is because this report is part of a report book, and it adds an extra "ghost" report when the reports are rendered, meaning, the extra pages are counted as if they were reports in the counter. So I don't want this report broken into many pages when I am doing the HTML review (or just the review)

    regards
  8. Stef
    Admin
    Stef avatar
    3036 posts

    Posted 26 Jul 2013 Link to this post

    Hello Wadigzon,

    Check the answer in the mentioned by you forum thread.

    In future please avoid posting the same question multiple times. If it is an emergency use our ticketing system to contact us, as this is the best way to reach our support staff.

    Regards,
    Stef
    Telerik

    Have you tried the new visualization options in Telerik Reporting Q2 2013? You can get them from your account.

Back to Top
DevCraft banner