on 05-01-2007 8:40 AM
Hello everyone!
I am new to this sapscript. My sapscript works ok but when I am viewing over 30 records of data I am getting this pop-up error:
<b>WRITE_FORM is invalid, START_FORM is missing</b>
When I am using less than or equal to 30 records, the sapscript works just fine. I know there is something I dont know yet because im just a <u>newbie</u>. Can you pls help me?
big thanks to all of you.
-
data: ITAB type table of STXL with header line.
select TDOBJECT TDNAME TDID CLUSTR
from STXL
into corresponding fields of table ITAB
up to 36 rows.
CALL FUNCTION 'OPEN_FORM'
EXPORTING
APPLICATION = 'TX'
FORM = 'Z_STXLSCRIPT'.
LOOP AT ITAB.
CALL FUNCTION 'WRITE_FORM'
EXPORTING
ELEMENT = 'RECORD1'
FUNCTION = 'SET'
TYPE = 'BODY'
WINDOW = 'MAIN'.
ENDLOOP.
CALL FUNCTION 'CLOSE_FORM'.
OK MY PROBLEM NOW IS SOLVED. THANKS TO <b>TAMAS </b>FOR HELPING ME TO FIGURE OUT. THANKS TO ALL OF YOU. but i got another problem.
What I did was, I have main window on page 1 and on page 2. I deleted the main window and I have no window on page 2. I did the print preview and it worked on 30, 40, 50, 60 records.
BUT when I tried 80 records, it gave me a new error message:
<b> Output is continuous or contains too many pages (>3)</b>
<b>Questions:</b>
1. With the new error message, could this be because I only have 2 pages?
2. on the Print preview, why i see only 1 page instead of 2? I do have 2 pages on the layout though.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi!
I'm glad, you solved it. If you satisfied with the answer, just click on the left side of the post, and give some points for it.
Answers:
1. No, it can't be, because you told to sapscript to print another PAGE2 style page after the second page. Thisis what you defined within the nextpage property.
The pages will come as the following list:
1. PAGE1 -> nextpage PAGE2
2. PAGE2 -> nextpage PAGE2
3. PAGE2 -> nextpage PAGE2
4. PAGE2 and so on...
2. On the print preview, you can switch between the pages with the PageUp and Pagedown buttons.
It's better if you open a new thread to a new question. More people will read it.
Regards
Tamá
<b>TAMAS: </b>I already updated that and it is posted above your post. I still have the same problem
the same image posted above:
http://i150.photobucket.com/albums/s116/painkiller2007/mypages.jpg
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi!
Have you set it to both pages?
PAGE1 -> nextpage PAGE2
PAGE2 -> nextpage PAGE2
If it is still not working, comment out the text element from your window.
Replace
/E RECORD1
with
/* RECORD1
/* means the comment in SAPScript.
SAVE and ACTIVATE
your SAPScript.Are you testing it in the same system/client?
Regards
Tamá
I already updated the NEXT setting (on pages) and still the same.
see image:
http://i150.photobucket.com/albums/s116/painkiller2007/mypages.jpg
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
<b>VINAY</b>: the element "RECORD1" is existing. in fact, my sapscript is working good when using only 30 records or less than 30 records BUT when over 30 records, that error message is coming up.
window setting:
http://i150.photobucket.com/albums/s116/painkiller2007/my_windows.jpg
paragraph setting:
http://i150.photobucket.com/albums/s116/painkiller2007/my_paragraph.jpg
pages setting:
http://i150.photobucket.com/albums/s116/painkiller2007/my_pages.jpg
design code:
http://i150.photobucket.com/albums/s116/painkiller2007/my_designcode.jpg
<b>PLS HELP</b>. im really new to this field.<b> thanks. </b>
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi!
Aha, I see your problem now. You don't have NEXT page, only PAGE1 and PAGE2.
At the PAGE1, please give the next page as PAGE2 and NOT NEXT.
Maybe that text element is created in MORE windows. You can create it only once in a SAPScript.
Personally I'm using text elements (/E) only in the MAIN window. In other windows it is not neccesary, because it is enough to address them by their window name.
Regards
Tamá
Hi Boy,
If you are calling any element with the WRITE_FORM function module, it should exists the element in the window in the layout, othewiese it will show the error stating that WRITE_FORM is invalid, START_FORM is missing.
Check whether you assigned NEXPAGE attribute in your layout??
<b>OPEN_FORM:</b> This form opens the script. The module OPEN_FORM opens layout set printing.
<b>WRITE_FORM:</b> This form is used to write the content mentioned in the windows of the SAP Script.
<b>START_FORM:</b> This form is dynamically call a page in the script. The layout set can be changed in the current print procedure with START_FORM. This may also be used to trigger a new-spool id.
<b>END_FORM:</b> This form is used to close the current layout set.
<b>CLOSE_FORM:</b> This form close the current SAP script form.
<b>You can have any number for WRITE_FORM, START_FORM and END_FORM, but for a script you can have only one OPEN_FORM and CLOSE_FORM.</b>
Thanks,
Vinay
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
another question. When do you use START_FORM?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
89 | |
10 | |
10 | |
9 | |
7 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.