Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
BedrockMission!

Learn more

View all

Sign in to view all badges

SOLVED

AEM Designer - Force Page Break

chapmawi
Level 2
Level 2

Hello All,

I'm new to AEM (LiveCycle) Designer but I thought I had mastered the basic stuff.  That was until someone asked me force a page break in a document that currently contains information by state in a table object inside a flowed subform.  The request is to have the table data element begin on a new page each time the state changes.  I thought such a request would be really simple (and it probably is) but I can't find an explanation of how to do it.

Thanks in advance!

Willie C.

1 Accepted Solution
_Bruce_Robertson
Correct answer by
Level 10
Level 10

Hi Willie C,

Sounds like you could use the conditional break option on the Row object of your table, so something like;

1500620_pastedImage_0.png

The code

if (this.index > 0) {

  this.resolveNode('Row1[-1].State').rawValue

    !=

  State.rawValue;

}

Assume your row is called Row1 and the state field is called State.  The reference "this.resolveNode('Row1[-1].State').rawValue" returns the State value on the previous row, so we don't want to execute this when we are on the first row "if (this.index > 0) {"

Regards

Bruce

View solution in original post

1 Reply
_Bruce_Robertson
Correct answer by
Level 10
Level 10

Hi Willie C,

Sounds like you could use the conditional break option on the Row object of your table, so something like;

1500620_pastedImage_0.png

The code

if (this.index > 0) {

  this.resolveNode('Row1[-1].State').rawValue

    !=

  State.rawValue;

}

Assume your row is called Row1 and the state field is called State.  The reference "this.resolveNode('Row1[-1].State').rawValue" returns the State value on the previous row, so we don't want to execute this when we are on the first row "if (this.index > 0) {"

Regards

Bruce

View solution in original post