Options

Report shows loads wrong dataitem on wrong page

CaponeCapone Member Posts: 125
edited 2015-05-27 in NAV Three Tier
Hi experts!

Here is a tough one!

We have a swedish localized swedish invoice report.

Problem:
The problem consists of that we have textboxes in the footer that should be shown on the last page which works fine (invoice sums).
The problem appears when you have so many lines on the first page that the dynamic footer fields won't fit on the first page but all the lines does. Resulting in a first page that contain all the lines and an empty second page except the header and the sums.

So in this scenario we have Invoice1 (2 pages), Invoice2 (1 page) and Invoice3 (1 page). When Invoice1 processes it notices that the dynamics footer sum field won't fit on the first page so it creates a page 2. On page 2 there are no sales lines left to print, just the header and the footer with the invoice sums. But now it instead shows the header information from invoice2! So even tough it hasn't finished the current dataitem record it starts reading the information on the next dataitem record. This doesn't happen in preview mode, but in pdf, paper and print to XPS.
What happens next is that the "data item record pointer" is out of sync. When it comes to page 3 that should contain invoice2 contains the header information of invoice3 and the lines of invoice2. This continues for all the other invoices in the cue.

As I said this ONLY happens when the lines fit on the first page and the dynamic footer fields is pushed to the second page. All other invoices are ok.

More technical description.
From NAV all header information is stored in text variable is transfered to the layout with the name DataArray under the CopyLoop dataitem.
In the layout the DataArray is stored in uppermost left field of the tablix. That tablix line is hidden.
The second line in the tablix is the lines header. In most left field under the hidden expression is the setdata function called.

When the second page prints there is no header.

I have managed to recreate the problem on the standard localization report by making the footer bigger. But I haven't managed to recreate the problem by timing the amount of lines with a page break. This made me try to make the footer smaller but that didn't help, instead the problem turned up again on another invoice.

First time we found it it looked ok in all modes except on the printer and printing to PDF. The second time it only looks ok in the preview mode.

I would be glad for suggestions. [-o<
Hello IT, have you tried to turn it off and on?
Have you checked the cables?
Have you released the filters?

http://www.navfreak.com

Comments

  • Options
    clauslclausl Member Posts: 455
    Hi Capone,

    Can you send me the Report.rdlc and Dataset.xml files for your report, then I will suggest what you should do?

    I will not provide me e-mail address here, but if you think about my user ID here and the Company I work for it should be easy to figure out.

    If not, write me a private message.

    /Claus Lundstrom
    Claus Lundstrøm | MVP | Senior Product Manager | Continia.com
    I'm blogging here:http://mibuso.com/blogs/clausl and used to blog here: http://blogs.msdn.com/nav
    I'm also offering RDLC Report Training, ping me if you are interested. Thanks to the 700 NAV developers that have now already been at my training. You know you can always call if you have any RDLC report issues :-)
Sign In or Register to comment.