2006 Dec 08 4:41 AM
Hello Experts,
I'm trying to printing customer invoice line item in a form. But it is only printing 1st line of the line item.
I'm trying to print all documents of the table BSEG.
Please advice if I need any coding in SAP scripts.
If I need any ABAP coding then please let me know where I should write it.
My SAPscript code looks like:
code]
/E 20 520
/* - Line items heading -
T1: &BKPF-BLDAT&,,&BSEG-BELNR&,,&BSEG-SGTXT& ,,,,&BSEG-WRBTR&
T1: ,,&RF140-VTEXT',,&RF140-MSATZ&%,,,,&RF140-MWSHB&'&
T1: ,,,,,,,,&uline(20)&
T1: ,,,,,,,,&RF140-GSALDF&
[/code]
Thanks
Hello Experts,
I'm trying to printing customer invoice line item in a form. But it is only printing 1st line of the line item.
I'm trying to print all documents of the table BSEG.
Please advice if I need any coding in SAP scripts.
If I need any ABAP coding then please let me know where I should write it.
My SAPscript code looks like:
code]
/E 20 520
/* - Line items heading -
T1: &BKPF-BLDAT&,,&BSEG-BELNR&,,&BSEG-SGTXT& ,,,,&BSEG-WRBTR&
T1: ,,&RF140-VTEXT',,&RF140-MSATZ&%,,,,&RF140-MWSHB&'&
T1: ,,,,,,,,&uline(20)&
T1: ,,,,,,,,&RF140-GSALDF&
[/code]
Thanks
2006 Dec 08 4:50 AM
Hi Nazmul ,
Are you using the standrad driver program .
If yes please debug the script and see how may times is the element used to print the item details called.
To Activate debugging (SE71-->Utilities -->Activate Debugging)
Regards
Arun
2006 Dec 08 5:11 AM
Hi Arun,
1st I would like to inform you that I'm new to ABAP.
When I run the program by turning on the debug it starts with program RFKORB00.
I'm generating the document by
1. txn f.62.
2. Get variant ... and choose CUST INV
3. And then execute.
So yes it is standard driver program. Do I need to write my own driver program to loop through the BSEG table or the standard program should loop through the table and display in the form. As I've declared the table fields name in the line item section?
Please advice.
2006 Dec 08 5:16 AM
Hi Nazmul ,
I am not clear with what changes you have made (i am referring to the last line).
Have you tried one entire cycle of debugging , please try doing it , it will be of help to you .
Reagrds
Arun
2006 Dec 08 5:30 AM
Hi Arun,
I have copied the form F140_DOCU_EXC_02 to /FJANZLG/YINVOIC and now trying to display &BKPF-BLDAT&,,&BSEG-BELNR&,,&BSEG-SGTXT& ,,,,&BSEG-WRBTR& in line item section.
How do I do that. It is displaying ony 1 line item even though the BSEG table contains 5 lines.
Thanks a lot for your prompt answer.
Naz
2006 Dec 08 5:37 AM
Hi Nazmul ,
There values are already there in the text element 521 of the standard form.
What all changes have you made in your custom form.
Please also test using the standrad form and see what is its output , does it show all the 5 line items
Reagrds
Arun
2006 Dec 10 9:11 PM
Hi Arun,
I have only modified the table fields.
The Main window of standard form F140_DOCU_EXC_02 displaying field from tables BSEG, BKPF, RF140, RF140 and has the following code:
[code]
/E 520
/* - Line items heading -
AS
UL &uline(71)&
T1 <k>Doc.No.,,,,Date</>
UL &uline(71)&
/E 521
/* - Line items heading -
T1 &BSEG-BELNR&,,,,&BKPF-BLDAT&,,&RF140-WAERS&,,&RF140-WRSHB&
T1 ,,&BSEG-SGTXT&
T1 &RF140-VTEXT',,&RF140-MSATZ&%,,,,&RF140-WAERS&,,&RF140-MWSHB&'&
T1 ,,,,,,,,&uline(20)&
T1 Brutto,,,,,,&RF140-WAERS&,,&RF140-GSALDF&
[/code]
And the custom form has the following code:
-
[code]
/E 520
/* - Line items heading -
AS
UL &uline(71)&
T1 <k>Date,,Invoice. No.,,Text,,,,Amount (NZ$)</>
UL &uline(71)&
/E 521
/* - Line items heading -
T1 &BKPF-BLDAT&,,&BSEG-BELNR&,,&BSEG-SGTXT& ,,,,&BSEG-WRBTR&
T1 ,,&RF140-VTEXT',,&RF140-MSATZ&%,,,,&RF140-MWSHB&'&
T1 ,,,,,,,,&uline(20)&
T1 ,,,,,,,,&RF140-GSALDF&[
[/code]
2006 Dec 08 4:52 AM
Hi,
Check if you have looped your text element in the driver program.
Regards,
pankaj singh
2006 Dec 08 5:34 AM
Nazmul
call the looped item in main window only. In a main windom, assign a element and the same has been called in ur code after loop statement.
It will work
2006 Dec 10 8:58 PM
Did you mean the data item as loop item? Which code are you talking about?
Can please provide some example?
Thanks a lot in advance.
| User | Count |
|---|---|
| 3 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |