IMPORTANT ANNOUNCEMENT

These forums were permanently set to read-only mode on July 20, 2022. From that day onwards, no new posting or comment is allowed on the site, but the historical content remains intact and searchable.

A new location for posting questions about PlanetPress Suite is now available:

OL Learn - PlanetPress Classic (opens in new tab)

Topic Options
#55829 - 03/27/18 09:49 AM Counter on Variable Layouts Across Multiple Record
Shift Offline
OL Newbie

Registered: 03/27/18
Posts: 5
I'm trying to use the counter to always increment by one across a variable number of layouts and across multiple records. 0-99, then loop back around.

I'm basically trying to get it so it runs like the following:

Record 1
Layout 1: 0
Layout 2: Skipped
Layout 3: 1
Layout 4: 2
Layout 5: 3

Record 2
Layout 1: 4
Layout 2: 5
Layout 3: Skipped
Layout 4: Skipped
Layout 5: 6

Record 3
Layout 1: 7
Layout 2: 8
Layout 3: 9
Layout 4: Skipped
Layout 5: 10

Record 4
Layout 1: 11
Layout 2: 12
Layout 3: 13
Layout 4: 14
Layout 5: 15

...and so on

The closest I've gotten so far is with this expression:

COUNTER(PAGE_NR()-1, 99, 1, 2, True)

But it is jumping a number between each new record.

Also, I know that the above code wont loop back around to 0 after reaching 99, I was just trying to solve one problem at a time wink

Thanks


Edited by Shift (03/28/18 04:51 AM)

Top
#55841 - 04/03/18 10:39 AM Re: Counter on Variable Layouts Across Multiple Record [Re: Shift]
MartinS Offline
OL Guru

Registered: 08/06/12
Posts: 142
Loc: Munich
Why not just using the Modulo function instead of the counter:

MOD(PAGE_NR() - 1, 100)

That way you're counting from 0 to 99 in a loop.

Top