cancel
Showing results for 
Search instead for 
Did you mean: 

Smartforms - new page command at loop

Former Member
0 Kudos

Hi @ll,

I`ve created a loop over an internal table in which I have insert a command to go to next page. The command is being called correctly but I don`t get data on the next page. I would expext that the loop goes on with the next record. Currently have just one page - could that be the problem?

What I`m doing wrong?

Ragards,

Flo

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

Remove the command. In the page-->general attribute tab, mention ur next page(if u r having one page mention same page).

Regards,

Ramesh.

Former Member
0 Kudos

If have an internal table

-


PerNr | Text

-


1 | Test1

1 | Test2

2 | Test2

3 | Test2

3 | Test2

3 | Test2

Each PerNr should be printed on a new page. Currently I`ve defined a next page command in a loop. The command refers to the same page.

Madhurivs23
Participant
0 Kudos

loop at this table in main window.

in the table add command and give next page after displaying the fields in the table.

Former Member
0 Kudos

Hi Florian,

Follow this Wiki example https://www.sdn.sap.com/irj/scn/wiki?path=/display/abap/pageBreakin+SMARTFORMS

Regards,

Marcin

Former Member
0 Kudos

Hi,

Can you try it with Table node. In table node Main area Call the Command node for Next page for every new record by providing required condition to Command node.

Answers (4)

Answers (4)

Former Member
0 Kudos

Hi,

In the internal table add one more field called flag and in the driver program populate the value of flag = 'X' at the end of every PERNR using Control break statements.

In the loop and the command give the condition as Flag = 'X'.

So the Page break will be triggered when ever the PERNR value will be changed.

Hope this will help you.

Regards,

Venkat.

Madhurivs23
Participant
0 Kudos

Hay,

write that command in the main window at the last of all in that main windowand not in between .

rgds,

Madhuri

Former Member
0 Kudos

There is only one page in your smartform.So you are calling the same page over and over again.You want to print each record on the new page.

Use the following:

1) in the Next page attributes as the First page.

2) Adjust the Main Window Size So that only one records fits or create Templete in the main windows.

3) Remove the command.

4) After each record Next page will be automatically triggered..

Regards,

Gurpreet

hadiman_ngoei
Participant
0 Kudos

Can you explain in more detail what is your requirement? Thanks