cancel
Showing results for 
Search instead for 
Did you mean: 

In smartform,footer should come for every page except for the last page

Former Member
0 Kudos

Hi All,

Iam printing customer details in my program using smartforms . Inside the smartforms I want to print a text element in every page except in the last page. How do I go about it?

Ex: Actually I am printing the word "continue" in the bottom right corner of every page but it is coming for the last page also even if there is no other page to print .

Please do the needful.

Thanks in advance.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

Use the following condition where u r printing 'CONTINUE'.

IF sfys-page < sfsy-formpages .

Ur code for printing 'CONTINUE'.

ENDIF.

SFSY-PAGE will give you the current page and SFSY-FORMPAGES will give you the total no. of pages.

e.g. Total No. of pages = 10.

then it will check the condition at 10 th page as,

10 < 10.

by this way it will skeep the 'CONTINUE' statement for last page.

Hope this will help.

Regards,

Mukesh J.

Answers (5)

Answers (5)

Former Member
0 Kudos

Hi Smiriti ,

To stop printing it in the last page try using &NEXTPAGE& .

/: if &NEXTPAGE& NE 0 (that is not a last page)

you wite or else for the last page you leave it .

Much Regards,

Amuktha .

Former Member
0 Kudos

Hi Smriti

you can avoide the CONTINUE in your last page by creating a second page with 2 windows.

Create a MAIN WINDOW of the same width as in the first page MAIN WINDOW of type M

and a SECONDARY WINDOW of type L( FINAL WINDOW ).

Go to the CONDITIONS tab of the SECONDARY WINDOW of page 2

and give the condition

SFSY-PAGE NE SFSY-FORMPAGES

Then create the text element for this window (Text element : CONTINUE.......)

Activate the form and run the program.

Otherwise you can do it in the same page itself(PAGE1) by creating a SECONDARY WINDOW

and create a text element for this window (Continue....).

In the condition tab of TEXTELEMENT check the EVENT ' Only Before End Of Main Page '.

Activate the form and run the program.

Both the ways will give you the same result.

Try this .This will solve your porblem.

Regards

Hareesh Menon

Edited by: Hareesh Menon on Feb 7, 2009 10:16 AM

Former Member
0 Kudos

Ignore this post.

Former Member
0 Kudos

PLS IGNORE THIS POST

Former Member
0 Kudos

Hi Smriti

Declare the variable in the global definitions with the default value 1.

Create the secondary window and In the condition tab of the text node Check the check box Only before end of the main window .

Regards,

Sravanthi