PageFooter missing or truncated - sometimes

Posted by: cartocracy on 4 August 2017, 2:37 pm EST

  • Posted 4 August 2017, 2:37 pm EST


    I have a report I've been running for years with no problems. Suddenly, sometimes (and I can't find any common thread) the PageFooter section either starts way down on the page and has the bottom of it cut off, or is missing entirely.

    The report consists of an empty, zero-height PageHeader, a GroupHeader, a Detail section, a GroupFooter, and a PageFooter. The Detail section has CanGrow and CanShrink set to true, and because of the data it contains, it (along with the GroupHeader and GroupFooter) never grows large enough for there not to be plenty of space for the PageFooter at the bottom of the page.

    Any ideas or suggestions? Thanks!

    Greg Carter

  • Replied 4 August 2017, 2:37 pm EST

    The only times I've seen issues like this is when the height of a pageheader/pagefooter is adjusted in a format event, which is not supported.  Generally the heights of these sections should remain static, and the CanGrow and CanShrink properties set to false.  I realize that by default they are set to true, but these sections are not meant to contain dynamic data and therefore are not designed to handle CanGrow/CanShrink. 

    So make sure CanGrow and CanShrink are set to false for the PageFooter section, the controls within the section are not growing, and that the size is not being adjusted through code.  If the sizes are required to change, the only safe place to do so is in the PageStart event.  However, no data from the report is available in this event, so the new height needs to be predetermined.
  • Replied 4 August 2017, 2:37 pm EST

    Thanks, PeterDD. I'm not doing anything to set the height of the PageHeader or PageFooter in code, but I am setting the Visible property of some elements in the PageFooter to True or False in the ReportStart event.

    The CanGrow and CanShrink properties are indeed set to True; I'll set them to false and see if that helps.
  • Replied 4 August 2017, 2:37 pm EST

    FYI - making any changes to a layout in ReportStart is perfectly fine.  So I do not suspect that to be a problem.  However, if you are adjusting heights or positions, you may try calling SaveLayout after the changes are made.  This allows you to open up the saved RPX and visually verify that the layout is correct.
  • Replied 4 August 2017, 2:37 pm EST

    Hi Peter,

    Thanks, I'm glad that's not causing any problems.

    I've never used SaveLayout, and there's no reference to it in the ActiveReports Reference help file using either Index or Find. Where could I find some documentation on how, when, and why to use it?

  • Replied 4 August 2017, 2:37 pm EST

    Weird unexplained behavior may be the result of corrupted designer files, put a backup copies into use, one from when it was working would be necessary.
  • Replied 4 August 2017, 2:37 pm EST

    Thanks for the suggestion, wsmith.

    Unfortunately, my client is not sure when the problem began, and I have recently made some (seemingly-unrelated) changes to this report. Is there any way to regenerate or clean up the designer file as it stands today?


  • Replied 4 August 2017, 2:37 pm EST

    I pulled a backup on the one that I had a weird issue on similar to this and didn't investigate further since it resolved the issue.

    Thoughts on things to try might be...
    1) Do a Save As and put it under a new filename.

    2) Copy and paste your code and controls from the buggy one to a new AR, you would still have to setup any section properties differing from the defaults.

    Anyone from the DD team have any input on this?
  • Replied 4 August 2017, 2:37 pm EST

    The helpfile documentation on SaveLayout can be found here:

    It allows you to save the layout in its current state.  You can open this RPX file in the designer by selecting the designer's (not the IDE's) File, Open menu option. 
Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels