Aged report totals not re-setting when print to pdf

dlerouxdleroux Member Posts: 87
edited 2012-11-14 in NAV Three Tier
I'm just not thinking of the right search strings - or has no one noticed this?

If you run either Aged Accounts Payable or Aged AR reports in RTC and select the "Print - PDF" option on the report request page (new feature as of last November), the report totals are not resetting. For example, if you run a base report 10085 (Aged Accounts Payable) and use the PDF option, the report will be fine the first time, but the second time you run it, the totals will double, then triple and so on. If you mix things up and run the report in preview mode, the totals come out correctly, but if you then run it again with print PDF, it picks up where it left off (quadruple, etc.). Exiting the RTC or recompiling the report resets the total, but the problem remains.

Both these reports have timestamps of 11/05/08 and versions are NAVNA6.00

Has MSFT released a hotfix or update that addresses this? I'm just not seeing it if so.

Thanks in advance.

Comments

  • MarkHamblinMarkHamblin Member Posts: 118
    Yep - it's an issue. Haven't seen a hotfix posted, but one of our other developers spent some time sorting it out. Here's the fix:

    In each report, add a new function in the VB code:
    Public Function ResetTotalBalancesDue() as Decimal
       TotalBalanceDue = 0
       TotalBalanceDue1 = 0
       TotalBalanceDue2 = 0
       TotalBalanceDue3 = 0
       TotalBalanceDue4 = 0
    End Function
    

    Then add a hidden text box in the body before the table with the value set to an expression that calls the function. Here's the added text box copied from the text of the report's RDL:
    ...
    <ReportItems>
    <Textbox Name="textbox3">
    	<Height>0.16645in</Height>
    	<Left>1.625in</Left>
    	<Style>
    		<Color>Red</Color>
    		<FontSize>7pt</FontSize>
    		<Format>=First(Fields!TotalBalanceDue__Format.Value)</Format>
    		<PaddingBottom>2pt</PaddingBottom>
    		<PaddingLeft>0.075cm</PaddingLeft>
    		<PaddingRight>0.075cm</PaddingRight>
    		<PaddingTop>2pt</PaddingTop>
    		<VerticalAlign>Middle</VerticalAlign>
    	</Style>
    	<Value>=Code.ResetTotalBalancesDue()</Value>
    	<Visibility>
    		<Hidden>true</Hidden>
    	</Visibility>
    	<Width>0.76844in</Width>
    	<ZIndex>6</ZIndex>
    </Textbox>
    <Table Name="table1"> ...
    

    Hope that helps.

    - Mark
  • rico1931rico1931 Member Posts: 295
    Yep - it's an issue. Haven't seen a hotfix posted, but one of our other developers spent some time sorting it out. Here's the fix:

    In each report, add a new function in the VB code:
    Public Function ResetTotalBalancesDue() as Decimal
       TotalBalanceDue = 0
       TotalBalanceDue1 = 0
       TotalBalanceDue2 = 0
       TotalBalanceDue3 = 0
       TotalBalanceDue4 = 0
    End Function
    

    Then add a hidden text box in the body before the table with the value set to an expression that calls the function. Here's the added text box copied from the text of the report's RDL:
    ...
    <ReportItems>
    <Textbox Name="textbox3">
    	<Height>0.16645in</Height>
    	<Left>1.625in</Left>
    	<Style>
    		<Color>Red</Color>
    		<FontSize>7pt</FontSize>
    		<Format>=First(Fields!TotalBalanceDue__Format.Value)</Format>
    		<PaddingBottom>2pt</PaddingBottom>
    		<PaddingLeft>0.075cm</PaddingLeft>
    		<PaddingRight>0.075cm</PaddingRight>
    		<PaddingTop>2pt</PaddingTop>
    		<VerticalAlign>Middle</VerticalAlign>
    	</Style>
    	<Value>=Code.ResetTotalBalancesDue()</Value>
    	<Visibility>
    		<Hidden>true</Hidden>
    	</Visibility>
    	<Width>0.76844in</Width>
    	<ZIndex>6</ZIndex>
    </Textbox>
    <Table Name="table1"> ...
    

    Hope that helps.

    - Mark

    Thanks Mark,

    Have you found that the same code fix goes for report #2 General Journal - Test.... Our Accounting department has been complaining about the same issue.
    -rico1931
  • MarkHamblinMarkHamblin Member Posts: 118
    rico1931 wrote:
    Have you found that the same code fix goes for report #2 General Journal - Test.... Our Accounting department has been complaining about the same issue.
    I imagine a similar fix would apply to the GL test report, though we haven't specifically fixed that one (yet).
Sign In or Register to comment.