cancel
Showing results for 
Search instead for 
Did you mean: 

Page repeat

Former Member
0 Kudos

Hi

I have created one smartform, the requirement is to create one form for each order in a period(month).

This form has 4 pages. for eg. i have three orders for the month of may. So three forms should be created, each having 4 pages.so in total there should be 12 pages(3 forms X 4pages each).

the problem i am facing is that an extra page is created(13th). so how to avoid that extra page which is not required.

Please help me..

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi,

Along with that define the two variables in the global definition as

g_cnt type sy-tabix.

g_flg type c .

->in the initialization tab

g_cnt = lines( the table name which you are using in the main

window to display sales order).

Now you have the total no of lines in the g_cnt.

in the loop which is in main window write the program line pass the output parameter as g_flg.

in the condions tab give the condition as g_cnt = sy-tabix.

in the source code of that program lines

g_flg = 'X'.

now for the command node in the codition tab give the condition as g_flg ne 'X'.

Now you will not get the extra page.

Thanks,

NN.

Edited by: Nethaji babu on May 15, 2008 8:05 AM

Former Member
0 Kudos

Hi Nethaji,

Here i have 4 pages. And only in first page is having main window. And also in first page i have created text elements also. so extra page is having these text elements.

Former Member
0 Kudos

Hi,

Where are you printing the orders in the first page or in the remianing three pages.

If you are printing the orders in the first page you might have

been looping the internal table and you might be using the command node you have to apply previously reply logic in here.

What is for the text elements you have created will that contain any data or it is empty.

Thanks,

NN.

Former Member
0 Kudos

Hi,

I am not printing any orders. But i am picking the details based on the sales order and printing that details.There i am looping the internal table. So if there is no details then also it is printing the first page. That page is not empty also. Like it is having so many text elements so it is printing all the text elements.

Former Member
0 Kudos

Hi,

In that loop ar you using the event node If you are using it should be end of event node not at begin of node.

If you are printinig the sales order details that means you might be writing the driver program in that driver program itself you have to stop like

After select statement in the driver program we have to check the sales order internal table if that table is empty it we have to give error message and stop the processing there itself in the driver program.

Thanks,

NN.

Former Member
0 Kudos

Hi

In driver program its taking correct records. Its having 4 records only. Inside smartform while looping i have given event on end .

Former Member
0 Kudos

I want to know to things

1).Whether any new lines/ empty lines are there in your main window check all the text elements by click the text elements edit icon.

2).want to know the pages you define in your

form & its sequence

i.e. Page & its Next Page

& any command nodes are used for any page

please let us know all this.

Thanks,

Phani.

former_member216668
Participant
0 Kudos

in your 4th page do you use any table? cuz sometimes if you had created a table which is nearly the size of the page, then there is a possibility that with some data being displayed this table can grow bigger and move to next page, there by creating a blank page. Mostly this problem is due to design issue.

Former Member
0 Kudos

Hi

i have used table in forth page. But it is not that much bigger and also the blank page is coming na that is first page only. bcoz i have created text elements there. So the repeating page is same as first page without data. How can i avoid this.

former_member216668
Participant
0 Kudos

Introduce a Program line and a flag.

Set the flag in the fourth page at end of main window when count of users is exhausted.

Then add this flag as condition in the place where the new page is triggered.

Have a cond like.

G_flag ne 'X'.

then trigger the page.

former_member216668
Participant
0 Kudos

Hema,

Check this thread it may help you

Cheers

Former Member
0 Kudos

Hi

In my form only in first page is having main window. So i cannot create command node in forth page. Please tell me what to do