‎2006 Oct 04 3:29 PM
Hi,
hope u r doing well .i have small doubt i.e i have 3 text messages in a internal table(in print program),i want to show all these messages in my form output ,but it is showing only last message .pls give ur suggestion with an example.i m waiting for ur reply....
thx in adv.
Regds,
Prabhas
‎2006 Oct 04 3:33 PM
Hi,
Use the below Function module,
CALL FUNCTION 'WRITE_FORM_LINES'
EXPORTING HEADER = HEADER
TABLES LINES = LINES1
EXCEPTIONS UNSTARTED = 1
UNOPENED = 1
OTHERS = 9.
hope, it will solve your problem.
cheers.
santosh.
‎2006 Oct 04 3:34 PM
HI,
i think in write_form function module.. for FUNCTION u have given DELETE.. give as SET...
<b>CALL FUNCTION 'WRITE_FORM'
EXPORTING
ELEMENT = 'UR TEXT MESSAGE'
FUNCTION = 'SET'
TYPE = 'BODY'
WINDOW = 'MAIN'
.</b>
hope this helps..
if not post ur code.. so we can check more
‎2006 Oct 04 3:34 PM
In your sapcript, put the lines of the internal table in the MAIN window and put them under an element.
/E TEXT_LINES
PF &iTextLines&Now in your print program, loop the internal table and write each line one by one.
loop at itextlines.
call function 'WRITE_FORM'
exporting
element = 'TEXTLINES'
window = 'MAIN'.
endloop.
Regards,
Rich Heilman
‎2006 Oct 04 3:35 PM
Your printer program have to look like this
LOOP AT itab INTO wa.
CALL FUNCTION 'WRITE_FORM'
ELEMENT 'MESSAGE'
ENDLOOP.
And the SAPScript:
/E MESSAGE
ZZ wa-message
Regards
Tamá
‎2006 Nov 16 9:39 AM
Hi,
I am facing the same problem with internal table. All records are not getting printed on sapscript.Last record of internal table is getting printed.
I am using following code in print program
loop at t_bset1.
CALL FUNCTION 'WRITE_FORM'
EXPORTING
ELEMENT = '252'
FUNCTION = 'SET'
TYPE = 'BODY'
WINDOW = 'SUB_TOTL'.
endloop.
W1 <B>VAT &t_bset1-wrbtr_pers(C)&%</>,,&t_bset1-fwste&
Please help me solve the problem.
Message was edited by:
Sid Kumar