on 05-16-2012 9:19 AM
Hi ,
I have request to rapaire page numbering problem in sap script.
The code is
Page:,,&PAGE& of &SAPSCRIPT-FORMPAGES& I tried with Page:,&PAGE& of &SAPSCRIPT-FORMPAGES(C)&
The problem is whathever is the number printed pages on the form it is always printed
"Page : 1 of 1"
So if I have 5 pages form on each of them is printed tha same thing - 1 of 1.
Please advice .
Chris
Hello Krsto,
Check Whether yo have assigned next page or not.
Thnaks
vijay
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Chris,
i use
Page &PAGE& / &SAPSCRIPT-FORMPAGES(2)&
and it works fine.
The (2) indicates the max. length of the page. 2 digits so the highest value is 99.
I don't know what (C) stands for.
Regards
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Georg ,
Thanks but it doesn't work with your solution. I am wondering is that problem with Page standard attributes.
In the script I found two pages 'FIRST' and 'NEXT'
Page : FIRST
NextPage: NEXT
Page counter is set in following manner
MODE: INC
Numb type : Arabic
Output length : 00 ( i changed lately into 02 but nothing has change in numbering)
Please advice
Chris
Hi ,
Thanks . It works but only partially i replaced SAPSCRIPT-FORMPAGES(3ZC)& with
&SAPSCRIPT-JOBPAGES(2C)& and now the total pages is ok.
Page no is still 1 for all five pages so instead having 1 of 1 now i have 1 of 5 on all pages.
Jobpages I inserted from insert>simbols>sapscrip i tried to find something for page but i didn't found it.
Only one was in insert>simbols>TTXSY (ttxsy-page) but this one doesn't work.
I did try in start mode but without success.
Please advice
Chris
Hi Krsto,
While writing Print program you have to use START_FORM...END_FORM for different pages.
CALL FUNCTION 'OPEN_FORM'
EXPORTING
FORM = 'ZTEST'.
CALL FUNCTION 'START_FORM'
EXPORTING
STARTPAGE = 'PAGE1'.
CALL FUNCTION 'WRITE_FORM'
EXPORTING
ELEMENT = 'ITEMDETAILS'
WINDOW = 'MAIN'.
CALL FUNCTION 'WRITE_FORM'
EXPORTING
WINDOW = 'ADDRESS'.
CALL FUNCTION 'END_FORM'.
CALL FUNCTION 'START_FORM'
EXPORTING
STARTPAGE = 'PAGE2'.
CALL FUNCTION 'WRITE_FORM'
EXPORTING
ELEMENT = 'ITEMDETAILS'
WINDOW = 'MAIN'.
CALL FUNCTION 'WRITE_FORM'
EXPORTING
WINDOW = 'PAGES'.
CALL FUNCTION 'WRITE_FORM'
EXPORTING
WINDOW = 'FOOTER'.
CALL FUNCTION 'END_FORM'.
CALL FUNCTION 'CLOSE_FORM'.
In the script form in page numbers in the text element of a window write this code,
PAGE &PAGE& of &SAPSCRIPT-JOBPAGES&
User | Count |
---|---|
84 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.