how about a calculated footer, based on last record (which should only appear on the last page)?
Lastpage_summary_c = If ( get ( foundcount ) = get ( recordnumber )
; << show your summary info here >>
; "" )
Put this calculated field on the footer where appropriate.
Thanks for the tip. Will try in the morning. I did an initial stab and the get ( recordnumber ) was returning a figure of my total records, as opposed to the number location in my found set.
In addition, I would have liked the summary information to contain horizonal lines, as you would expect ion invoice information.
Anyway, I shall provide an update in the morning.
Eric, this is a little more advanced, but you can do some TEXT FORMATTING to the calculated footer. In addition, FileMaker has Conditional Formatting for objects (including text & field objects), that allows you to add something fancy (again based on the same forumla to display or not). These are colors, text formatting, etc. (see the following links for more info:)
But importantly this para in the HELP: "You can set conditional formatting on the following layout objects: text, fields (including fields from external ODBC data sources), merge fields, layout symbols (date, time, page number, record number, and so on), text-based buttons, web viewers, and tab panels. Conditional formatting is not available for non-textual objects (such as a rectangular layout object)."
So you may need to create an additional "text" box (plain - contains one or more spaces with transparent fill) and set the border(s) in some way to simulate your "horizontal lines" and use conditional formatting on them. Or your calculated field may have border(s) applied to it with conditional formatting. Play around with these cool tools a little and see what you get!
& hmmm on your error
Get ( RecordNumber ) - according to help - "Returns the number of the current record in the current found set." So, maybe you don't have the calculation as "unstored"? If it's set once, it may not update. If you have FMAdvanced, can you put this value into Data Viewer and see what you get?
Hi Beverly, thanks for the further update. Your conditional formatting tip led me to consider using something like a field whose colour could change to mask/unmask the summary info. However, my main problem is ensuring data will only appear at the bottom of the last page. I should have initially pointed out that I am printing from a List view, which could mean that I am printing something like 20 records over say, 2 pages. Placing data in a footer puts it at the bottom of every page (as opposed to every record), and of course a Title Footer places the info at the bottom of the first page only. I just wish Filemaker contained a Footer part that placed information on the last page only. If a formula existed that was something like get ( printpagenumber ), then I could use conditional formatting to make the Summary info appear on the last page.
Yes, Filemaker can easily get record numbers, but can it also get page numbers?
1. There is no good solution to this problem.
2. You could force the data in the footer to appear only on the last page (using either a calculation field or conditional formatting) - but the height of the footer remains constant, meaning that the footer is likely to take up a lot of unnecessary space on all previous pages.
3. IIRC, Ray Cologon came up with a rather complex method of adding more and more carriage returns in a trailing grand summary part, until the number of pages increases - then pulling back by one.
Yes, this is certainly a tough nut to crack. I think the way forward is to accept unwanted space on previous pages. (The summary info isn't that large.) I'm going to explore also the conditional route to make it appear on the last page. Am I right in thinking this utilizes calculation fields that will go to the last page and sets a field with the page number, then use an if formula for the conditional process?
Am I right in thinking this utilizes calculation fields that will go to the last page and sets a field with the page number, then use an if formula for the conditional process?
Not exactly. You do need to start by getting the number of the last page. Once you have that, say in $$variable, you can conditionally format text to disappear whenever =
Get (PageNumber) < $$lastPageNum
Note that Get (PageNumber) makes sense only in Preview/Print.
Problem solved, thanks to both Beverly and Michael. I still regard myself as a bit of a novice, and I hope I can return the favour to a fresh faced newbie!
For your information, I used conditional formatting by employing a field that would turn white (thus masking the summary info) when the last page did not equal the current page number. This was placed in the footer part. Yes, unwanted space in previous pages, but a small price to pay.
That's why you only show on the last RECORD (list view or not). Yes, you can get the last page, but it's a hack. I'll see if I have time to work up a demo later to day.
-- sent from my iPhone4 --
Hi all - helpful information here.
Funny how some things escape you - I was frustrated by a subsummary that wouldn't work because my footer was too long. It wasn't until I read this that I realised the footer needed to go at the bottom of every page, not just at the bottom of the last page.
Have seperated out the long footer for the client into a seperate layout and appended it via scripting to the end of the report.