cancel
Showing results for 
Search instead for 
Did you mean: 

SAPScript - add 'continued' in next page.

Former Member
0 Kudos

Hi Guys,

I would like to ask on how to write 'continued' at the new page?

My SAPScript form is depend on the data that will output. When the data is exceeded from the MAIN window, it will automatically break the data to pages. So may i know how i want to write 'continued' when it breaks the data to the new page?

Accepted Solutions (0)

Answers (7)

Answers (7)

Former Member
0 Kudos

i taught like that too, but does is that the best way to do it?

or is there another way to do it?

Thanks for the answer.

Former Member
0 Kudos

Hi,

i gave you a lot of possibilities now

1. to print at the TOP of the MAIN window (with TOP .... ENDTOP)

2. to print at the BOTTOM of the MAIN window ( with BOTTOM .... ENDBOTTOM)

3. to create a window near the MAIN so it seems in the MAIN even a hint for if you are using a frame around it.

4. you can put a window anywhere in the page with your text Continued.

What do you want more?

Gr., Frank

Former Member
0 Kudos

ok thanks for all the answers....

Former Member
0 Kudos

hi buddy i'm not so proficient in abap but i guess u have 100 datas and say if suppose 50 is printed in 1st page and when next 50 is gonna be printed in next page u wanna put [continued] is it?

sol: total line count of the itab = 100 and last line of the internal table line in that current page say 50 now put if 50<=100 to be continued.u can vary 50 and 100 i suppose.

Former Member
0 Kudos

I appreciate all the answer.

But it still doesn't answer to the question.

What i meant is i want to print 'continued' not at the bottom of the page, but i want to print it before the data output.

For example:

I have to output 100 sets of data.

but the page can output 50 sets of data.

the other 50 sets of data will be output at the next page.

before it print 50 set of data at the next page, i want to ouput, 'continued' before the data be output.

more appropriate example is like an article in the magazine. when reach one point of the articel,

it will be continued to the next page. Before it continued to the article, it will show 'continue(name of article)'.

That what i want...

The whole data sets is in 1 element.

when i put condition of new page, it will write continued each line of the data at the next page.

How i want to output 'continued only at the begining of the page?

Former Member
0 Kudos

Hi,

If you want it at the top you can use /: top ...... /: endtop

Put this at the start of your item. (including the page condition)

If you think it won't work or it is to difficult.

make an extra window very close to your main and put the text (with the page condition) in it.

if you use a frame around your main window you can resize that with the BOX, SIZE and POSITION commands so that extra window will seems like a part of the main.

Hope this helps.

Gr., Frank

TOP: Set header text in MAIN

In MAIN, lines that are always automatically output at the top of the window, called header texts, can be determined. Header texts can automatically repeat the table heading at the top of every page for an extensive tabular list.

Syntax:

/: TOP

:

:

/: ENDTOP

Those text lines between the two commands will be output at the top of MAIN.

To switch a header text off, enter the command pair TOP .. ENDTOP, with no lines in between:

/: TOP

/: ENDTOP

Header text will not appear on subsequent pages.

Former Member
0 Kudos

Hi,

Try this.

You have the footer command. to print text at ther bottom in the main window.

See description of it below

Gr. Frank

BOTTOM: Define footer text in a window

For MAIN, determine the lines, also known as footer texts, which are always automatically output at the bottom of that window.

Syntax:

/: BOTTOM

:

:

/: ENDBOTTOM

The text lines between the two commands are output at the bottom of MAIN.

To switch a footer text off, enter the command pair BOTTOM .. ENDBOTTOM with no text lines in between:

/: BOTTOM

/: ENDBOTTOM

Footer text no longer appears at the bottom of the page from and including this page.

Former Member
0 Kudos

addition.

Between bottom and endbottom you must put a condition to take care that the text will not be printed at the last page.

/: bottom

/: if &page(C)& NE &SAPSCRIPT-FORMPAGES(C)&

  • TEXTTEXT

/: endif

/: endbottom

Former Member
0 Kudos

Does that call function will print the footer window?

Former Member
0 Kudos

HI,

Try this oen

Call this 101 element in this way from Driver program

CALL FUNCTION 'WRITE_FORM'

EXPORTING

ELEMENT = '101'

  • FUNCTION = 'SET'

TYPE = 'FOOTER'

WINDOW = 'MAIN'

EXCEPTIONS

ELEMENT = 1.

/E 101

/: if new page

  • continued

/: endif

Former Member
0 Kudos

Thanks for the answer.

But how if i want to write 'continued' in the main window?

For example:

in my main window the output will be like this:

data 1

data 2

data 3

......(and so on)

if the 'data 2' has reach the end of the page, 'data 3' will be print in next page. I want to know how to write 'continued' before the 'data 3' be printed?

i tried to put this coding in the text element,


/E 101
/:  if new page
/:  continued
/:  endif
&symbol&

but the out put will be like this:

continued

data 3

continued

data 4

continued

data 5

...(and so on)

The 'continued' statement will be repeating on each line of data.

Edited by: BobKur on Jun 19, 2009 9:43 AM

Former Member
0 Kudos

HI,

Create a Footer window in right side bottom corner, and write 'Continued, but you need to write this text with in a condition.

IF &NEXTPAGE& <> 0.

<Write the text>.

ENDIF.

OR

/: IF &PAGE(3ZC)& = &SAPSCRIPT-FORMPAGES(3ZC)&

  • [your END OF PAGE text here]

/: ENDIF

Another option is to simply check if &NEXTPAGE& ='0'. This should achieve the same results.