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

Print value only on last page

Lucyalison
Level 1
Level 1

Hi,

we have a pay-in slip on each page of an invoice. The amounts on that pay-in slip should be stars (like *********) and only on the last page of the invoice the pay-in amount should be printed.

I tried the following already:

Formcalc on event initilize:

var curpage = $layout.page ( ref ( $ ) )

var totpages = $layout.pageCount()

if ( curpage ne totpages ) then

$.rawValue = "*******"

Endif

Result: The stars were printed on both pages of the invoice.

Then I tried the following coding:

Javascript on event ready:

if (xfa.layout.page(this) != xfa.layout.pageCount()){

     this.rawValue == "*******"

}

Result: The invoice amount is printed on both pages.

I am an ABAP developer and not very experienced with Formcalc or Javascript. I would be very grateful if somebody could help me here.

Kind Regards
Nicola

0 Replies