Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×
The Claris Museum: The Vault of FileMaker Antiquities at Claris Engage 2025! ×

Stopping page breaks within parts


This topic is 7352 days old. Please don't post here. Open a new topic instead.

Recommended Posts

  • Newbies
Posted

How do I stop page breaks within a part and start it the next part on the next page instead? The report is multiple heirarchal sub-summaries of varying lengths so page break after __occurances is not the best solution. Also need it to keep the whole part together (i.e. - can't discard rest of part)

Each category has multiple sub-summaries and not always the same quantity. Report looks like...

Category1

- Sub1

- Sub1a

- Sub1b

Category2

- Sub2

Category3

- Sub3

- Sub3a

- Sub3b

- Sub3c

- Sub3d

So it needs to break at the end of the page before a new category starts, not in the middle of the subs. Average number of categories that fit on a page is between 8 and 9

Any tips and helpful hints would be much appreciated!

Posted

From FM Help:

To define page breaks and page numbering for a part:

1. In Layout mode, choose Layouts menu | Part Setup.

2. In the Part Setup dialog box, select the part, then click Change.

You can also double-click the part label on the layout.

3. In the Part Definition dialog box, specify pagination options.

The following table describes the pagination options that are available. Dimmed options are not available for the selected part type.

Start a new page before printing the contents of the selected part (for example, to print a trailing grand summary on a new page)

Page break before each occurrence.

Start a new page after printing the contents of the selected part a specified number of times (for example, to print five records in the body, and then start a new page)

Page break after every <value> occurrences, and enter the number of part occurrences that you want per page. (The default value of 1 prints one part occurrence per page.)

Reset the page number to 1 after the selected part prints (for example, to start page numbering after a title header if you want it to serve as a cover page)

Restart page numbers after each occurrence.

Allow the contents of the selected part to be split on different pages, printing a portion at the bottom of one page, and the rest on the next page.

(FileMaker Pro won't split the contents of a part across two pages unless you specify this option, or the height of the part won't fit on a single page.)

Allow part to break across page boundaries.

To keep the portion of the part that will not fit on the bottom of the page from printing at the top of the next page, also select Discard remainder of part before new page (for example, to print the information in a Notes field to the bottom of the page and truncate the rest).

Display a different background color and pattern in alternating records for the selected body part

Alternate background fill, and choose a fill color and pattern from the pop-up menus.

Note Even-numbered records use the alternate background fill specified here. Odd-numbered records use the background fill specified for the body part object. For information on setting the fill for the body part object, see Setting color, pattern, line width, and object effects.

4. Click OK, then click Done.

Therefore, select a new page break before each occurrence of category. HTH.

  • Newbies
Posted

Thanks, but I'm trying to get it to page break before starting the next part when the height of the part doesn't fit on the page.

Setting to break after every X occurrences semi-solves the issue, but with an average of 8 sub-summaries with 1-5 records per summary, some pages end short while some look perfect.

Posted

I have the same problem as CaliforniaEd. And, sadly, it appears to me that the lengthy response from transpower (quoting the Help file) boils down to "You can't get there from here".

I'm trying to print a phonebook of members of my organization (a church). I have a file of individuals (with their names, other data specific to them as individuals). I also have a linked file of households (with address, phone, etc). I sort the file of individuals first by location (local or remote), then by household, and within household by individual names.

So the "body" records are the names, and the trailing sub-summary after names is the (one) household address that is common to all the names in that household.

In the "Parts Definition" dialogs, turning off "allow part to break across page boundaries" merely prevents the trailing summary itself from being split, but does nothing to keep the trailing summary on the same page as the body that precedes it.

I'm still hoping to find something equivalent to the common word-processing command "keep with preceding."

Posted

I have a complex invoicing solution that uses a calculation field instead of a subsummary part to keep at least one record with the 'subsummary', so that it isn't completely orphaned. It requires using a script to Copy All Records on a layout containing only the serial. This result is then pasted into a global text field on another layout. There is a calculation to determine what the next record's serial is, based on the position of the current record's serial in the global, and a relationship from this calculation to the serial field. Then, the final calculation tests if the current break field matches that of the next record, using the relationship, and returns a Sum result if it does not match.

Case( breakfield <> nextrecord::breakfield, Sum(breakfield::number) )

where breakfield:: is a self-relationship based on the breakfield and number is the field to be summed. This calculation field is then placed in the body and formatted to slide up when empty. It only contains a value on the last record in each subsummary set; so it simulates a subsummary part. I have a similar calculation that retrieves a line graphic from a global container field placed directly above the Sum field, creating an even more convincing pseudo-subsummary.

Before the Copy All Records step runs, the script tests whether there are too many records to remain within FM's 64k limit.

If [status(CurrentFoundCount) * ({length of serial field} + 1) - 1 > 64000]

Show Custom Dialog ["Please reduce your found set further."]

Halt Script

End If

The total size of the Copy All Records step will be the length of the serial plus one character for the carriage return, times the number of found records, minus one since the final serial will not be followed by a carriage return.

This topic is 7352 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.