Sapscript table
Hi
It is possible to do something like this:
I have loop in sapscript by itab wchich print:
name1 name2_very_very_lo name3
name1 name2_very_very_lo name3
And I wanto to split a name2 to like this:
name1 name2_very_very name3
........._long_name
name1 name2_very_very name3
........._long_name
How to split this long strings to 2 lines?
Edited by: Kosmo on Aug 1, 2008 4:54 PM
<MOVED BY MODERATOR TO THE CORRECT FORUM>
Edited by: Alvaro Tejada Galindo on Aug 2, 2008 8:19 AM
Hi,
Firstly can i know the use of splitting into second line... as you have a option to move your cursor to left or right in EDIT menu..
Even then if you want to mention in the next line then put and '=' symbol in the command field which resembles the continuation of previous line.
Hope this would help you.
Good luck
Narin
Similar Messages
-
Tab setting in the main window sapscript table
Hi ,
i have one problem ,i am doveloping new script.in the main window having 5 column table .the table col size is grater than the populated field size.main problem is these values are not populated in the middle of the every column of the table.
to achive this how to set the tabsettings?
please sent the solution for this asap.
Thanking u.Hi SS,
U can do that by giving the alignment (Right,Left,Center Alignment) in the Pragraph format and also in Character format.......
any of the format you can choose....
as for as tab is concern you must have the size of the value which you want to populate...
accordingly you have to give the tab size in paragraph format...
thnx
Rohit -
FI document correspondence sapscript table entries
Hi there,
In document display transaction FB03, I am printing form by menu = environment -> correspondence -> AR.
There are 5 line items displayed in form. I want to add some more conditions in the internal table used to shorten it. I have heard that I cannot put conditions in internal table through SE71 as it just uses the current table line at a time. So I have to do all the logic before the form is being called. Also I want to sum the amounts before the form is being called.
Can you please identify any user exit in transaction FB03 or any other way that I could work with the internal table before the form is being called. Is there any other way except of user exit that I could use with this standard sap program.
Thanks in advance !
Best regards,
JohnnyHi J ,
do u know the Form name and Driver Program name ?
Regards
Peram -
Hi experts!!
I'm trying to get the deductions certificate (RPC190E0) in PDF format.
If we customize to get this certificate in SAPSCRIPT (table V_T799BSFT) the result is correct.
But if we customize to get this certificate in PDF when we run the report we get this error:
Device type unsuitable for ADS documents
Message no: SPADS011
Kind regards,
JulianJulian,
Talk to your system guy, Adobe Document Server (ADS) need to be setup correctly in your landscape.
Further help on printer configuration for ADS
[http://help.sap.com/saphelp_nw70/helpdata/en/25/6fa8fd27837846990a7a6813b06f80/content.htm]
Your message is probably issued after evaluation of the following function:
CALL FUNCTION 'ADS_GET_DEVTYPE_ATTRIBUTES'
EXPORTING
prtype = prts-type
IMPORTING
adstype = adstype.
IF adstype IS INITIAL.
sy-subrc = 3.
MESSAGE s011.
RETURN.
ENDIF.
So you can always debug and check what parameter is missing.
I have had the same problem in the past, talked with my system guy who solved it out.... misconfiguration of printers...
Hope it helps.
Regards. -
How i can add document nu in below query
i want to add one field in below query
field is bkpf-xblnr
i want document number after d_text.
here d_text = 'Payment for'
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'D_TEXT'.
tab_out-value = d_text.
MODIFY tab_out INDEX sy-tabix.
please help
thanks in advanced.hi help yar i m totaly new for this
i m pasting whole code here just see yar and where u changing please hight light that things
thanks yar
PROGRAM zfisp0001.
*& Subroutine pool ZFISP0001 *
*& Author: Rakesh Rao on 01.04.05 *
*& Modified by: Rakesh Rao on 15.07.2005 *
*& Description: This subroutine pool is called from Check and Payment *
*& Advice SAPScripts *
TABLES: itcsy.
TYPES: BEGIN OF t_itcsy.
INCLUDE STRUCTURE itcsy.
TYPES: END OF t_itcsy.
DATA: tab_in TYPE STANDARD TABLE OF t_itcsy WITH NON-UNIQUE
DEFAULT KEY INITIAL SIZE 0.
DATA: tab_out TYPE STANDARD TABLE OF t_itcsy WITH NON-UNIQUE
DEFAULT KEY INITIAL SIZE 0.
DATA: d_count(3) VALUE 0,
d_netamt_tot TYPE p DECIMALS 2,
d_tdsamt_tot TYPE p DECIMALS 2,
d_grossamt_tot TYPE p DECIMALS 2,
d_tdsamt TYPE p DECIMALS 2.
DATA flag.
DATA: bschl LIKE bseg-bschl.
DATA: shkzg LIKE bseg-shkzg.
clear: d_count,d_netamt_tot.
*& Form ZPAYMENT
text
--> p1 text
<-- p2 text
FORM zpayment TABLES tab_in STRUCTURE itcsy
tab_out STRUCTURE itcsy.
tables : bsak.
TYPES: imis_type_c20(20) TYPE c,
imis_type_c10(10) TYPE c.
DATA: l_intern TYPE imis_type_c20.
DATA: e_intern TYPE imis_type_c10.
DATA: i_extern TYPE imis_type_c10.
DATA: d_belnr(10),
D_VBLNR(10),
d_bukrs TYPE bseg-bukrs,
d_gjahr TYPE bseg-gjahr,
d_gjahr1 TYPE bseg-gjahr, " 15.07.2005 Rakesh
d_buzei TYPE bseg-buzei,
d_augbl TYPE bseg-augbl,
d_umskz TYPE bseg-umskz,
d_bschl TYPE bseg-bschl,
d_bktxt TYPE bkpf-bktxt,
d_budat(10),
d_rebzg TYPE bseg-rebzg,
D_SHKZG TYPE REGUP-SHKZG,
d_swnes TYPE regud-swnes,
d_netamt TYPE p DECIMALS 2,
d_tdsamt TYPE p DECIMALS 2,
d_discamt TYPE regud-wskto,
d_gross TYPE regud-wrbtr.
DATA: BEGIN OF t_bkpf,
bukrs TYPE bkpf-bukrs,
belnr TYPE bkpf-belnr,
gjahr TYPE bkpf-gjahr,
budat TYPE bkpf-budat,
bktxt TYPE bkpf-bktxt,
xblnr TYPE bkpf-xblnr,
END OF t_bkpf.
DATA: BEGIN OF t_bseg,
bukrs TYPE bseg-bukrs,
belnr TYPE bseg-belnr,
gjahr TYPE bseg-gjahr,
buzei TYPE bseg-buzei,
umskz TYPE bseg-umskz,
bschl TYPE bseg-bschl,
qbshb TYPE bseg-qbshb,
augbl TYPE bseg-augbl,
rebzg TYPE bseg-rebzg,
rebzj TYPE bseg-rebzj,
sgtxt TYPE bseg-sgtxt,
xref1 TYPE bseg-xref1,
ebeln TYPE bseg-ebeln,
shkzg type bseg-shkzg,
END OF t_bseg.
DATA: num VALUE ' ',
d_result VALUE ' '.
DATA: d_symbol VALUE '/',
d_text(11) VALUE 'Payment for'.
DATA: d_belnr1 LIKE bseg-belnr.
DATA: wa_payrq TYPE payrq. " 15.07.2005 Rakesh
18.05.2006
data : wa_belnr like bseg-belnr,wa_augbl like bseg-augbl.
18.05.2006
06.09.2006
data : d_other type p decimals 2.
Read incoming data
*break-point.
*zpayment.
CLEAR: d_belnr,d_bukrs,d_gjahr,d_result.
clear d_tdsamt.
Company code
CLEAR tab_in-value.
READ TABLE tab_in WITH KEY 'REGUP-BUKRS'.
d_bukrs = tab_in-value.
Document number
CLEAR tab_in-value.
READ TABLE tab_in WITH KEY 'REGUP-BELNR'.
wa_belnr = d_belnr(10) = tab_in-value(10).
Posting Key
CLEAR tab_in-value.
READ TABLE tab_in WITH KEY 'REGUP-BSCHL'.
d_bschl = tab_in-value.
Special G/L Indicator
CLEAR tab_in-value.
READ TABLE tab_in WITH KEY 'REGUP-UMSKZ'.
d_umskz = tab_in-value.
Fiscal year
CLEAR tab_in-value.
READ TABLE tab_in WITH KEY 'REGUP-GJAHR'.
d_gjahr = tab_in-value.
<-- 15.07.2005 Rakesh
Fiscal year1 - For Payment request case
CLEAR tab_in-value.
READ TABLE tab_in WITH KEY 'REGUD-GJAHR'.
d_gjahr1 = tab_in-value.
15.07.2005 Rakesh -->
Document item
CLEAR tab_in-value.
READ TABLE tab_in WITH KEY 'REGUP-BUZEI'.
d_buzei = tab_in-value.
Discount amount, if any
CLEAR tab_in-value.
READ TABLE tab_in WITH KEY 'REGUD-WSKTO'.
REPLACE ALL OCCURRENCES OF ',' IN tab_in-value WITH ' '.
d_discamt = tab_in-value.
Gross Amount
CLEAR tab_in-value.
READ TABLE tab_in WITH KEY 'REGUD-WRBTR'.
REPLACE ALL OCCURRENCES OF ',' IN tab_in-value WITH ' '.
d_gross = tab_in-value.
Gross Amount
CLEAR tab_in-value.
READ TABLE tab_in WITH KEY 'REGUD-WNETT'.
REPLACE ALL OCCURRENCES OF ',' IN tab_in-value WITH ' '.
d_netamt = tab_in-value.
Clearing document 18.05.2006
CLEAR tab_in-value.
READ TABLE tab_in WITH KEY 'REGUP-VBLNR'.
wa_augbl = tab_in-value.
DEBIT/CREDIT INDICATOR
CLEAR tab_in-value.
READ TABLE tab_in WITH KEY 'REGUP-SHKZG'.
d_SHKZG = tab_in-value(1).
IF d_netamt < 0 AND D_SHKZG = 'S'.
D_NETAMT = D_NETAMT * '-1'.
ENDIF.
Check document no. is clearing document than reset wnett = 0.
18.05.2006
select single * from bsak where augbl = wa_augbl
and bukrs = d_bukrs and gjahr = d_gjahr1.
if sy-subrc = 0 and wa_belnr = wa_augbl.
d_netamt = 0.
endif.
18.05.2006
Check if Down payment request
IF d_bschl = '39'.
This line item is not considered
d_result = 'X'.
ELSE.
Check if Down payment
IF d_bschl = '29'
and wa_augbl = wa_belnr. "18.05.2006
IF d_umskz EQ 'A'
OR d_umskz EQ 'B'
OR d_umskz EQ 'I'
OR d_umskz EQ 'M'
OR d_umskz EQ 'D'.
Put Document Number of the Payment Document value to 'd_belnr'
CLEAR tab_in-value.
READ TABLE tab_in WITH KEY 'REGUP-VBLNR'.
d_belnr = tab_in-value.
ENDIF.
ENDIF.
<--15.07.2005 Rakesh
Check if Payment request exists in 'payrq'
CLEAR wa_payrq.
Convert 'd_belnr' to 10 digits,if required
CLEAR: l_intern,e_intern.
CALL 'CONVERSION_EXIT_ALPHA_INPUT' ID 'INPUT' FIELD d_belnr
ID 'OUTPUT' FIELD l_intern.
e_intern = l_intern+10.
d_belnr1 = d_belnr.
CLEAR d_belnr.
d_belnr = e_intern.
SELECT SINGLE keyno augbl FROM payrq
INTO CORRESPONDING FIELDS OF wa_payrq
WHERE keyno = d_belnr.
IF sy-subrc = 0. " Yes
Take clearing document which is the required accounting document
d_belnr = wa_payrq-augbl.
Convert 'd_belnr' to 10 digits,if required
CLEAR: l_intern,e_intern.
CALL 'CONVERSION_EXIT_ALPHA_INPUT' ID 'INPUT' FIELD d_belnr
ID 'OUTPUT' FIELD l_intern.
e_intern = l_intern+10.
CLEAR d_belnr.
d_belnr = e_intern.
Assign 'd_gjahr1' to 'd_gjahr' as this is relevant here.
d_gjahr = d_gjahr1. " 15.07.2005 Rakesh
Get BSEG data
SELECT SINGLE bukrs belnr gjahr buzei augbl rebzg rebzj
sgtxt qbshb umskz bschl xref1 ebeln
FROM bseg INTO CORRESPONDING FIELDS OF t_bseg
WHERE bukrs EQ d_bukrs
AND belnr EQ d_belnr
AND gjahr EQ d_gjahr
AND buzei EQ d_buzei " not relevant
AND bschl EQ '25' " Posting key - Outgoing payment
AND koart EQ 'S' " G/L accounts
AND shkzg EQ 'S'. " Debit
ELSE. " No
For all other cases, we use this final logic, even though we have
taken d_belnr value from accounting doc no., in some earlier cases.
Put document number of the payment document(vblnr) value to 'd_belnr',
IF d_bschl = '29'
and wa_augbl <> wa_belnr. "18.05.2006
IF d_umskz EQ 'A'
OR d_umskz EQ 'B'
OR d_umskz EQ 'I'
OR d_umskz EQ 'M'
OR d_umskz EQ 'D'.
else.
CLEAR tab_in-value.
READ TABLE tab_in WITH KEY 'REGUP-VBLNR'.
d_belnr = tab_in-value.
endif.
else.
CLEAR tab_in-value.
READ TABLE tab_in WITH KEY 'REGUP-VBLNR'.
d_belnr = tab_in-value.
endif.
-->15.07.2005
Convert 'd_belnr' to 10 digits,if required
CLEAR: l_intern,e_intern.
CALL 'CONVERSION_EXIT_ALPHA_INPUT' ID 'INPUT' FIELD d_belnr
ID 'OUTPUT' FIELD l_intern.
e_intern = l_intern+10.
CLEAR d_belnr.
d_belnr = e_intern.
Get BSEG data
SELECT SINGLE bukrs belnr gjahr buzei augbl rebzg rebzj
sgtxt qbshb umskz bschl xref1 ebeln shkzg
FROM bseg INTO CORRESPONDING FIELDS OF t_bseg
WHERE bukrs EQ d_bukrs
AND belnr EQ d_belnr
AND gjahr EQ d_gjahr1
"changed by Bharat 15.04.2006 - d_gjahr1 contains payment doc fiscal yea
"r and d_gjahr contains invoice fiscal year
AND buzei EQ d_buzei "amisha 10-10-2005
AND bschl EQ '25' " Posting key - Outgoing payment
AND shkzg EQ 'S' "added by Bharat 17.04.2006
AND ( koart EQ 'K' OR koart EQ 'D').
<--15.07.2005 Rakesh
18.05.2006
in clearing document payment advice not consider TDS amount of
payment document
if wa_belnr <> wa_augbl and d_shkzg = 'S'.
t_bseg-qbshb = t_bseg-qbshb * '-1'.
d_netamt = d_netamt + t_bseg-qbshb.
t_bseg-qbshb = 0.
endif.
18.05.2006
ENDIF.
-->15.07.2005
Get corresponding BKPF data
If Down payment
IF d_bschl = '29'.
IF d_umskz EQ 'A'
OR d_umskz EQ 'B'
OR d_umskz EQ 'I'
OR d_umskz EQ 'M'
OR d_umskz EQ 'D'.
SELECT SINGLE bukrs belnr gjahr budat bktxt xblnr
FROM bkpf INTO CORRESPONDING FIELDS OF t_bkpf
WHERE bukrs EQ d_bukrs
AND belnr EQ d_belnr
AND gjahr EQ d_gjahr1.
"changed by Bharat 15.04.2006 - d_gjahr1 contains payment doc fiscal yea
"r and d_gjahr contains invoice fiscal year
ENDIF.
ELSE.
If Partial payment/On-account payment
IF t_bseg-augbl IS INITIAL.
On-Account case
IF t_bseg-augbl IS INITIAL.
IF t_bseg-rebzg IS INITIAL.
t_bseg-rebzg = t_bseg-belnr. " Payment Document Number
t_bseg-rebzj = t_bseg-gjahr. " Fiscal year
ENDIF.
ENDIF.
SELECT SINGLE bukrs belnr gjahr budat bktxt xblnr
FROM bkpf INTO CORRESPONDING FIELDS OF t_bkpf
WHERE bukrs EQ t_bseg-bukrs
AND belnr EQ t_bseg-rebzg
AND gjahr EQ t_bseg-rebzj.
ELSE.
FULL PAYMENT with Discount
clear d_tdsamt.
Following code added for GSPL by bharat06092006
if d_bukrs eq 'GSPL'.
DATA : V_TEXT(20) TYPE C.
V_TEXT = 'W%'.
SELECT SINGLE wrbtr FROM bseg
INTO d_tdsamt
WHERE bukrs EQ d_bukrs AND
belnr EQ d_belnr1 AND
gjahr EQ d_gjahr AND " Added by bharat on 10-04-2006 fiscal year
bschl EQ '50' AND
KTOSL EQ 'WIT' AND
QSSKZ NOT LIKE V_TEXT.
SELECT single wrbtr FROM bseg
INTO d_other
WHERE bukrs EQ d_bukrs AND
belnr EQ d_belnr1 AND
gjahr EQ d_gjahr AND " Added by bharat on 10-04-2006 fiscal year
bschl EQ '50' AND
KTOSL EQ 'WIT' AND
QSSKZ LIKE V_TEXT.
ELSE.
Added by bharat 06.09.2006
SELECT SINGLE wrbtr
FROM bseg INTO d_tdsamt
WHERE bukrs EQ d_bukrs
AND belnr EQ d_belnr1
AND gjahr EQ d_gjahr
" Added by bharat on 10-04-2006 fiscal year
AND bschl EQ '50' AND KTOSL EQ 'WIT'.
ENDIF.
SELECT SINGLE bukrs belnr gjahr budat bktxt xblnr
FROM bkpf INTO CORRESPONDING FIELDS OF t_bkpf
WHERE bukrs EQ d_bukrs
AND belnr EQ d_belnr
AND gjahr EQ d_gjahr1.
"changed by Bharat 15.04.2006 - d_gjahr1 contains payment doc fiscal yea
"r and d_gjahr contains invoice fiscal year
tab_in-value
*d_tdsamt_tot
ENDIF.
ENDIF.
IF sy-subrc = 0.
Sr. no. for Line items
d_count = d_count + 1.
ELSE.
Else, this line item is not considered
d_result = 'X'.
ENDIF.
ENDIF. " if d_bschl = '39'
Pass the output to the outgoing table 'tab_out', if 'd_result' is not
*set.
IF d_result = ' '.
Line count
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'COUNT'.
tab_out-value = d_count.
MODIFY tab_out INDEX sy-tabix.
Result flag
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'RESULT1'.
tab_out-value = d_result.
MODIFY tab_out INDEX sy-tabix.
Clearing document
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'AUGBL'.
tab_out-value = t_bseg-augbl.
MODIFY tab_out INDEX sy-tabix.
IF d_bschl <> '29'.
On-Account case
IF t_bseg-augbl IS INITIAL.
IF t_bseg-rebzg IS INITIAL.
t_bseg-rebzg = t_bseg-belnr. " Payment Document Number
ENDIF.
ENDIF.
ELSE.
Payment document request
IF NOT t_bseg-ebeln IS INITIAL. " First preference
t_bseg-rebzg = t_bseg-ebeln.
ELSE.
t_bseg-rebzg = d_belnr.
ENDIF.
ENDIF.
Number of the Invoice the Transaction Belongs to
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'REBZG'.
SHIFT t_bseg-rebzg LEFT DELETING LEADING num.
tab_out-value = t_bseg-rebzg.
MODIFY tab_out INDEX sy-tabix.
Document number - check use??
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'BELNR'.
tab_out-value = d_belnr. " check!!
MODIFY tab_out INDEX sy-tabix.
Net amount
d_netamt = d_gross - d_discamt - t_bseg-qbshb.
Gross amount
d_gross = d_netamt + d_tdsamt + t_bseg-qbshb.
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'NETAMT'.
tab_out-value = d_netamt.
SHIFT tab_out-value LEFT DELETING LEADING space.
MODIFY tab_out INDEX sy-tabix.
TDS Amount
IF t_bseg-qbshb IS INITIAL.
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'TDSAMT'.
tab_out-value = d_tdsamt.
SHIFT tab_out-value LEFT DELETING LEADING space.
MODIFY tab_out INDEX sy-tabix.
Added by bharat 06.09.2006
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'D_OTHER'.
tab_out-value = d_other.
SHIFT tab_out-value LEFT DELETING LEADING space.
MODIFY tab_out INDEX sy-tabix.
Added by bharat 06.09.2006
ELSE.
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'TDSAMT'.
tab_out-value = t_bseg-qbshb.
SHIFT tab_out-value LEFT DELETING LEADING space.
MODIFY tab_out INDEX sy-tabix.
ENDIF.
*Calculate Total Net amount & TDS amount which is stored in Global
*memory and accessed later
from 'FORM Z_TOTAL_AMT'
d_netamt_tot = d_netamt_tot + d_netamt.
d_grossamt_tot = d_grossamt_tot + d_gross.
d_tdsamt_tot = d_tdsamt_tot + t_bseg-qbshb + d_tdsamt + d_other.
CLEAR: tab_OUT-value,tab_out-name.
READ TABLE tab_OUT WITH KEY 'NETAMT_TOT'.
tab_out-value = d_netamt_tot.
shift tab_out-value left deleting leading space.
MODIFY tab_out INDEX sy-tabix.
Document Header text
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'BKTXT'.
IF d_bschl = '29'.
tab_out-value = t_bseg-sgtxt. " for down payment request
ELSE.
tab_out-value = t_bkpf-bktxt.
ENDIF.
MODIFY tab_out INDEX sy-tabix.
Reference Document Number - Header
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'XBLNR'.
IF d_bschl = '29'.
tab_out-value = t_bseg-xref1. " for down payment request
ELSE.
tab_out-value = t_bkpf-xblnr.
ENDIF.
MODIFY tab_out INDEX sy-tabix.
Symbol '/'
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'D_SYMBOL'.
tab_out-value = d_symbol.
MODIFY tab_out INDEX sy-tabix.
Text 'Payment for'
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'D_TEXT'.
tab_out-value = d_text.
MODIFY tab_out INDEX sy-tabix.
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'D_TEXT'.
tab_out-value = d_text.
tab_out-xblnr = t_bkpf-xblnr.
MODIFY tab_out by bkpf-xblnr INDEX sy-tabix.
Posting date
CLEAR d_budat.
CALL FUNCTION 'CONVERT_DATE_TO_EXTERNAL'
EXPORTING
date_internal = t_bkpf-budat
IMPORTING
date_external = d_budat
EXCEPTIONS
date_internal_is_invalid = 1
OTHERS = 2.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'BUDAT'.
tab_out-value = d_budat.
MODIFY tab_out INDEX sy-tabix.
ELSE.
Result flag
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'RESULT1'.
tab_out-value = d_result.
MODIFY tab_out INDEX sy-tabix.
ENDIF.
d_gross = d_netamt + d_tdsamt + t_bseg-qbshb.
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'GROSSAMT'.
tab_out-value = d_gross.
SHIFT tab_out-value LEFT DELETING LEADING space.
MODIFY tab_out INDEX sy-tabix.
ENDFORM. " ZPAYMENT
*& Form zamtwords
text - If only 'Net Amount' is required
--> p1 text
<-- p2 text
FORM zamtwords TABLES tab_in STRUCTURE itcsy
tab_out STRUCTURE itcsy.
DATA: d_swnet TYPE regud-swnes, " take character format type
d_swnet1 TYPE bseg-dmbtr.
d_words(160),
d_words1(80),
d_words2(80).
<-- 21.05.2005
DATA: d_words(160),
d_words1(80) TYPE c,
d_words2(80) TYPE c.
DATA: len TYPE i.
<-- 21.05.2005
*zamtwords
CLEAR tab_in-value.
READ TABLE tab_in WITH KEY 'REGUD-SWNET'.
d_swnet = tab_in-value.
REPLACE ALL OCCURRENCES OF '*' IN d_swnes WITH ' '.
REPLACE ALL OCCURRENCES OF ',' IN d_swnet WITH ' '.
d_swnet1 = d_swnet.
CLEAR d_swnet.
PERFORM z_conv_amt USING d_swnet1 CHANGING d_swnet.
Return 'SWNET1' without commas
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'SWNET1'.
d_swnet = d_swnet1.
tab_out-value = d_swnet.
MODIFY tab_out INDEX sy-tabix.
Amount in Indian currency format
CALL FUNCTION 'Z_SPELL_AMOUNT_INR'
EXPORTING
amount = d_swnet1
IMPORTING
rupees_str = d_words.
Adjust 'd_words' left aligned
SHIFT d_words LEFT DELETING LEADING space.
<-- 21.05.2005
Split 'd_words' into 'd_words1' and 'd_words2'
since 'DEFINE' in SAPScript displays maximum 80 characters
d_words1 = d_words(80).
d_words2 = d_words+80(80).
*CALL FUNCTION 'C147_STRING_SPLIT_AT_POSITION'
EXPORTING
i_string = d_words
i_position = 80
IMPORTING
E_HEAD = d_words1
E_TAIL = d_words2.
len = STRLEN( d_words ).
Only 80 characters can be passed to one SAPScript symbol
Split 'd_words' into 'd_words1' and 'd_words2'
since 'DEFINE' in SAPScript displays maximum 80 characters
Check if string split is required
IF len > 80.
d_words1 = d_words(80). " First 80
d_words2 = d_words+80(80). " Next 80
Introduce an initial space in 'd_words2' if 80th character in
'd_words1' is space, as this space is not considered when 'd_words1'
value is passed to the SAPScript, since we need proper spacing
between 'd_words1' and 'd_words2' in the Cheque layout.
IF d_words1+79(1) = ' '.
SHIFT d_words2 RIGHT BY 1 PLACES.
ENDIF.
ELSE.
d_words1 = d_words.
d_words2 = space.
ENDIF.
21.05.2005 -->
Amount in words1
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'WORDS'.
tab_out-value = d_words1.
MODIFY tab_out INDEX sy-tabix.
Amount in words2
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'WORDS1'.
tab_out-value = d_words2.
MODIFY tab_out INDEX sy-tabix.
ENDFORM. " zamtwords
*& Form z_address
text
--> p1 text
<-- p2 text
FORM z_address TABLES tab_in STRUCTURE itcsy
tab_out STRUCTURE itcsy.
DATA d_bukrs TYPE bseg-bukrs.
DATA: t_t001 TYPE t001,
t_adrc TYPE adrc.
CLEAR: tab_in-value,t_t001,t_adrc.
READ TABLE tab_in WITH KEY 'REGUP-BUKRS'.
d_bukrs = tab_in-value.
CALL FUNCTION 'K_READ_T001'
EXPORTING
i_bukrs = d_bukrs
IMPORTING
e_t001 = t_t001
EXCEPTIONS
not_found = 1
OTHERS = 2.
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ELSE.
CALL FUNCTION 'RTP_US_DB_ADRC_READ'
EXPORTING
i_address_number = t_t001-adrnr
I_NATION = ' '
I_READ_DB =
IMPORTING
e_adrc = t_adrc
EXCEPTIONS
not_found = 1
OTHERS = 2
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'ADRC-NAME1'.
tab_out-value = t_adrc-name1.
MODIFY tab_out INDEX sy-tabix.
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'ADRC-STREET'.
tab_out-value = t_adrc-street.
MODIFY tab_out INDEX sy-tabix.
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'ADRC-CITY1'.
tab_out-value = t_adrc-city1.
MODIFY tab_out INDEX sy-tabix.
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'ADRC-POST_CODE1'.
tab_out-value = t_adrc-post_code1.
MODIFY tab_out INDEX sy-tabix.
ENDIF.
ENDFORM. " z_address
*& Form z_total_amt
text
--> p1 text
<-- p2 text
FORM z_total_amt TABLES tab_in STRUCTURE itcsy
tab_out STRUCTURE itcsy.
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'NETAMT_TOT'.
tab_out-value = d_netamt_tot.
SHIFT tab_out-value LEFT DELETING LEADING space.
MODIFY tab_out INDEX sy-tabix.
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'TDSAMT_TOT'.
tab_out-value = d_tdsamt_tot.
SHIFT tab_out-value LEFT DELETING LEADING space.
MODIFY tab_out INDEX sy-tabix.
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'GROSSAMT_TOT'.
tab_out-value = d_grossamt_tot.
SHIFT tab_out-value LEFT DELETING LEADING space.
MODIFY tab_out INDEX sy-tabix.
ENDFORM. " z_total_amt
*& Form Z_NET_AMT
text
-->TAB_IN text
-->TAB_OUT text
FORM z_net_amt TABLES tab_in STRUCTURE itcsy
tab_out STRUCTURE itcsy.
TYPES: imis_type_c20(20) TYPE c,
imis_type_c10(10) TYPE c.
DATA: l_intern TYPE imis_type_c20.
DATA: e_intern TYPE imis_type_c10.
DATA: i_extern TYPE imis_type_c10.
DATA: d_belnr(10),
d_bukrs TYPE bseg-bukrs,
d_gjahr TYPE bseg-gjahr,
d_umskz TYPE bseg-umskz,
d_bschl TYPE bseg-bschl,
d_dmbtr1 TYPE bseg-dmbtr,
d_dmbtr(17). "prb16052006
d_dmbtr1 like regud-swnes. "prb16052006
DATA d_amt TYPE char18.
DATA: BEGIN OF t_bseg OCCURS 10,
bukrs TYPE bseg-bukrs,
belnr TYPE bseg-belnr,
gjahr TYPE bseg-gjahr,
buzei TYPE bseg-buzei,
dmbtr TYPE bseg-dmbtr,
wrbtr TYPE bseg-wrbtr,
umskz TYPE bseg-umskz,
bschl TYPE bseg-bschl,
qbshb TYPE bseg-qbshb,
NEbtR TYPE BSEG-nebtr, "prb13052006
END OF t_bseg.
<-- 21.05.2005
DATA: d_words(160),
d_words1(80) TYPE c,
d_words2(80) TYPE c.
DATA: len TYPE i.
<-- 21.05.2005
DATA wa_payrq TYPE payrq. " 15.07.2005 Rakesh
Read incoming data
CLEAR: d_belnr,d_bukrs,d_gjahr.
Company code
CLEAR tab_in-value.
READ TABLE tab_in WITH KEY 'REGUP-BUKRS'.
d_bukrs = tab_in-value.
Document number
CLEAR tab_in-value.
READ TABLE tab_in WITH KEY 'REGUP-BELNR'.
d_belnr(10) = tab_in-value(10).
Posting Key
CLEAR tab_in-value.
READ TABLE tab_in WITH KEY 'REGUP-BSCHL'.
d_bschl = tab_in-value.
Special G/L Indicator
CLEAR tab_in-value.
READ TABLE tab_in WITH KEY 'REGUP-UMSKZ'.
d_umskz = tab_in-value.
Fiscal Year
CLEAR tab_in-value.
READ TABLE tab_in WITH KEY 'REGUD-GJAHR'. " Note
CHECK sy-subrc = 0.
d_gjahr = tab_in-value.
Check if Down payment
IF d_bschl = '29'.
IF d_umskz EQ 'A'
OR d_umskz EQ 'B'
OR d_umskz EQ 'I'
OR d_umskz EQ 'M'
OR d_umskz EQ 'D'.
Put Document Number of the Payment Document value to 'd_belnr'
CLEAR tab_in-value.
READ TABLE tab_in WITH KEY 'REGUP-VBLNR'.
d_belnr = tab_in-value.
ENDIF.
ENDIF.
Check if Down payment request
IF d_bschl = '39'.
Put Document Number of the Payment Document value to 'd_belnr'
CLEAR tab_in-value.
READ TABLE tab_in WITH KEY 'REGUP-VBLNR'.
d_belnr = tab_in-value.
ENDIF.
<--15.07.2005 Rakesh
Check if Payment request exists in 'payrq'
CLEAR wa_payrq.
Convert 'd_belnr' to 10 digits,if required
CLEAR: l_intern,e_intern.
CALL 'CONVERSION_EXIT_ALPHA_INPUT' ID 'INPUT' FIELD d_belnr
ID 'OUTPUT' FIELD l_intern.
e_intern = l_intern+10.
CLEAR d_belnr.
d_belnr = e_intern.
SELECT SINGLE keyno augbl FROM payrq
INTO CORRESPONDING FIELDS OF wa_payrq
WHERE keyno = d_belnr.
IF sy-subrc = 0. " Yes
Take clearing document which is the required accounting document
d_belnr = wa_payrq-augbl.
Convert 'd_belnr' to 10 digits,if required
CLEAR: l_intern,e_intern.
CALL 'CONVERSION_EXIT_ALPHA_INPUT' ID 'INPUT' FIELD d_belnr
ID 'OUTPUT' FIELD l_intern.
e_intern = l_intern+10.
CLEAR d_belnr.
d_belnr = e_intern.
Get BSEG data
SELECT bukrs belnr gjahr buzei augbl rebzg rebzj sgtxt dmbtr wrbtr
qbshb nebtr
FROM bseg INTO CORRESPONDING FIELDS OF TABLE t_bseg
WHERE bukrs EQ d_bukrs
AND belnr EQ d_belnr
AND gjahr EQ d_gjahr
AND buzei EQ d_buzei
AND bschl EQ '25'
AND koart EQ 'S' " G/L accounts
AND shkzg EQ 'S'. " Debit
ELSE. " No
For all other cases, we use this final logic, even though we have
taken d_belnr value from accounting doc no., in some earlier cases.
Put document number of the payment document(vblnr) value to 'd_belnr',
CLEAR tab_in-value.
READ TABLE tab_in WITH KEY 'REGUP-VBLNR'.
d_belnr = tab_in-value.
-->15.07.2005
Convert 'd_belnr' to 10 digits.
CLEAR: l_intern,e_intern.
CALL 'CONVERSION_EXIT_ALPHA_INPUT' ID 'INPUT' FIELD d_belnr
ID 'OUTPUT' FIELD l_intern.
e_intern = l_intern+10.
CLEAR d_belnr.
d_belnr = e_intern.
*BSEG - PARTIAL PAYMT/FULL PAYMT WT DISC - Get Total Amount without Bank
*charges
SELECT bukrs belnr gjahr buzei augbl rebzg rebzj sgtxt dmbtr wrbtr
qbshb bschl NEBTR
FROM bseg INTO CORRESPONDING FIELDS OF TABLE t_bseg
WHERE bukrs EQ d_bukrs
AND belnr EQ d_belnr
AND gjahr EQ d_gjahr
AND buzei EQ d_buzei
AND bschl EQ '25'
AND ( koart EQ 'K' OR koart EQ 'D' ).
<--15.07.2005 Rakesh
ENDIF.
-->20.10.2005 By Yogesh.
CLEAR d_dmbtr.
IF sy-subrc = 0.
LOOP AT t_bseg.
d_dmbtr = d_dmbtr + t_bseg-dmbtr - t_bseg-qbshb.
SELECT SINGLE shkzg INTO (shkzg) FROM tbsl
WHERE bschl = t_bseg-bschl.
*BREAK-POINT.
*******prb13052
IF shkzg = 'S'.
d_dmbtr = d_dmbtr + t_bseg-wrbtr - t_bseg-qbshb.
ELSEIF shkzg = 'H'.
d_dmbtr = d_dmbtr - t_bseg-wrbtr - t_bseg-qbshb.
ENDIF.
IF shkzg = 'S'.
d_dmbtr = d_dmbtr + t_bseg-nebtr." - t_bseg-qbshb.
ELSEIF shkzg = 'H'.
if t_bseg-nebtr <> ''.
d_dmbtr = d_dmbtr - t_bseg-nebtr." - t_bseg-qbshb.
else.
d_dmbtr = d_dmbtr - t_bseg-wrbtr." - t_bseg-qbshb.
endif.
ENDIF.
*tables: reguh, payr.
select single * from reguh where zbukr = d_bukrs
and vblnr = d_belnr
and LAUFD+6(4) = d_gjahr.
*select single * from payr where zbukr = d_bukrs
*and vblnr = d_belnr
*and hbkid = reguh-hbkid
*and hktid = reguh-hktid.
*d_dmbtr = payr-rwbtr.
*if d_dmbtr < 0.
*d_dmbtr = d_dmbtr * ( -1 ).
*endif.
CLEAR tab_in-value.
READ TABLE tab_in WITH KEY 'REGUD-SWNES'.
d_DMBTR = tab_in-value.
translate d_dmbtr using '* '.
translate d_dmbtr using ', '.
condense d_dmbtr no-gaps.
d_dmbtr1 = d_dmbtr.
*******prb13052
ENDLOOP.
PERFORM z_conv_amt USING d_dmbtr CHANGING d_amt.
*Pass the Net Amount output to the outgoing table tab_out-name =
*'NETAMT_TOT'.
CLEAR: tab_out-value,tab_out-name.
READ TABLE tab_out WITH KEY 'NETAMT_TOT'.
tab_out-value = d_amt.
" For inserting '*' ahead of value
SHIFT tab_out-value LEFT DELETING LEADING space. """"????IMP
MODIFY tab_out INDEX sy-tabix.
Get the Amount in words for Indian currency
Can also use the FM 'HR_IN_CHG_INR_WRDS'
CALL FUNCTION 'Z_SPELL_AMOUNT_INR'
EXPORTING
amount = d_dmbtr1
IMPORTING
rupees_str = d_words.
Shift left since above Function Module introduces an initial space
SHIFT d_words LEFT DELETING LEADING space.
<-- 21.05.2005
*CALL FUNCTION 'C147_STRING_SPLIT_AT_POSITION'
EXPORTING
i_string = d_words
i_position = 80
IMPORTING
E_HEAD = d_words1
E_TAIL = d_words2.
len = STRLEN( d_words ).
Only 80 characters can be passed to one SAPScript symbol
Split 'd_words' into 'd_words1' and 'd_words2'
since 'DEFINE' in SAPScript displays maximum 80 charact -
How to create a table in SAPscript
Hello,
I am quite new at SAPscript, and cannot figure out how to create a table in my main window.
I have read this forum post : Script: tabs, boxes, tables but am having problems with the way to fill in tabs, so if someone could help me understand better I would be very grateful.
i need to create the following scenario:
|ITEM |MATERIAL |QTY |PRICE |CURRENCY | <-Headr
| xxxx |xxxxx |xxxx |xxxx |xxxx | <-Item
| xxxx |xxxxx |xxxx |xxxx |xxxx | .
| xxxx |xxxxx |xxxx |xxxx |xxxx | .
| xxxx |xxxxx |xxxx |xxxx |xxxx | .
| xxxx |xxxxx |xxxx |xxxx |xxxx | <-Item
Total Amount xxxx
I have created a paragraph format PF with all the necessary tabs.
1) How do I create the table and the dividing lines ?
In the line editor I typed
<b>/E</b> TABLE
<b>PF</b> Item,,Material,,Quantity,,Price,,Currency
(will these be translated when I translate the form with the SE63 transaction? Or should I put the technical name for them, for example: &BKPF-BELNR&,,&BKPF-UZEGF&,,etc ?)
what is the use of the <b>/E</b> TABLE ? All it does is print "/E TABLE" in my print preview... is this normal or did I forget to do something ?
2) now in the Items, how do I input the different elements ?
If I just type
<b>PF</b> &BSEG-BSHL&,,&BSEG-BSGY&,,etc will I get as many lines as I have items ?
I read on a forum that I need to type itab, but how do I syntax it so that it works with the technical info of a field?
&itab-BSEG-BSHL& doesn't work, I get an error message saying "unknow symbol itab-BSEG-BSHL"
Thank you in advanceHi Micol,
Create a window for the below ( Header window )
|ITEM |MATERIAL |QTY |PRICE |CURRENCY | <-Headr
<b>In text elements of this window write this
PH ,,ITEM,,MATERIAL,,QTY,,PRICE,,CURRENCY
Here PH is a paragraph format give appropriate tabs.</b>
| xxxx |xxxxx |xxxx |xxxx |xxxx | <-Item
| xxxx |xxxxx |xxxx |xxxx |xxxx | .
| xxxx |xxxxx |xxxx |xxxx |xxxx | .
| xxxx |xxxxx |xxxx |xxxx |xxxx | .
| xxxx |xxxxx |xxxx |xxxx |xxxx | <-Item
Assume the fields are
Item - itab-item
material - itab-material
quantity - itab-qty
price - itab-price
currency - itab-currency
<b>In text elements of main window write
/E TABLE
PI ,,&ITAB-ITEM&,,&ITAB-MATNR&,,&ITAB-QTY&
,,&ITAB-PRICE&,,&ITAB-CURRENCY&
</b>
In u r driver program
loop at itab
Call function 'WRITE_FORM'.
under element take 'TABLE'
window 'MAIN'
endloop -
In which table the lines of the SAPScript form text elements are found?
Hello,
I want to write a report analyzing the lines contained in the text elements of an SAPScript form. From which table can I select the data? Regards.
Lars.Sorry.. forgot to mention the FM name.
You can use FM 'READ_TEXT'.
pass 'ST' for ID.
and 'TEXT' for OBJECT
and pass the name of text element to NAME u will get the
text element. -
Purchase Order : printing table in the SAPScript.
Hi all,
I want to print taxes in the PO . I have created SAPScript from the standard Script MEDRUCK & also attached it to the Appln - EF, in the T-Code : NACT.
To pass the taxes i have written a code and that program i have called from the script. But, it is only the last entry in the internal table (it_out). I want to print all the taxes for the respective PO. And, the only last one tax entry in the it_out , it is showing in the print preview for 'Domestic PO', and, for 'Import PO', it is not showing any entry.
Plz, try to solve this problem.... if anybody could give me the proper solution of this problem, i will definitely reward the points to him.
I am giving the code that i have used in the report & in Script.
Code in the SAP Script...
/E ITEM_CONDITIONS
/: PROTECT
/: DEFINE &TYPE& = ' '
/: DEFINE &TEXT& = ' '
/: DEFINE &PER& = ' '
/: PERFORM GET_TAX IN PROGRAM ZMM_PO
/: USING &EKKO-EBELN&
/: CHANGING &TYPE&
/: CHANGING &TEXT&
/: CHANGING &PER&
/: ENDPERFORM
IN ,,&TEXT&,,&PER&
/: ENDPROTECT
Respective code in the Report
*& Form GET_TAX
text
-->IN_PAR text
-->OUT_PAR text
FORM GET_TAX TABLES IN_PAR STRUCTURE ITCSY
OUT_PAR STRUCTURE ITCSY.
TABLES : EKKO, "Purchasing Document Header
KONV, "Conditions (Transaction Data)
T685T. "Conditions: Types: Texts
DATA : BEGIN OF ITAB OCCURS 10.
DATA : EBELN LIKE EKKO-EBELN.
DATA : KNUMV LIKE EKKO-KNUMV.
DATA : END OF ITAB.
DATA : BEGIN OF ITAB1 OCCURS 10.
DATA : EBELN LIKE EKKO-EBELN.
DATA : KNUMV LIKE KONV-KNUMV.
DATA : KPOSN LIKE KONV-KPOSN.
DATA : KSCHL LIKE KONV-KSCHL.
DATA : VTEXT LIKE T685T-VTEXT.
DATA : KBETR LIKE KONV-kbetr.
DATA : WAERS LIKE KONV-waers.
DATA : KWERT LIKE KONV-kwert.
DATA : END OF ITAB1.
DATA : BEGIN OF IT_OUT OCCURS 10.
DATA : KSCHL LIKE KONV-KSCHL.
DATA : VTEXT LIKE T685T-VTEXT.
DATA : KBETR LIKE KONV-KBETR.
DATA : KWERT LIKE KONV-KWERT.
DATA : END OF IT_OUT.
DATA : PONO LIKE EKKO-EBELN.
DATA : NO LIKE KONV-KPOSN.
READ TABLE IN_PAR WITH KEY 'EKKO-EBELN'.
IF SY-SUBRC = 0.
PONO = IN_PAR-VALUE.
SELECT EBELN KNUMV
FROM EKKO
INTO TABLE ITAB
WHERE EBELN = PONO.
READ TABLE IN_PAR WITH KEY 'KONV-KPOSN'.
IF SY-SUBRC = 0.
NO = IN_PAR-VALUE.
LOOP AT ITAB.
MOVE ITAB-KNUMV TO ITAB1-KNUMV.
SELECT KNUMV KPOSN KSCHL KBETR WAERS KWERT
FROM KONV
INTO CORRESPONDING FIELDS OF ITAB1
WHERE KNUMV = ITAB-KNUMV
AND KAPPL = 'M'.
ITAB1-KBETR = ( ITAB1-KBETR / 10 ) .
APPEND ITAB1.
ENDSELECT.
ENDLOOP.
SORT ITAB1 BY KPOSN kschl.
LOOP AT ITAB1.
IF ITAB1-KPOSN <> ''.
SELECT *
FROM T685T
WHERE KSCHL = ITAB1-KSCHL
AND KAPPL = 'M'
AND SPRAS = 'EN'.
IT_OUT-VTEXT = T685T-VTEXT.
IT_OUT-KSCHL = ITAB1-KSCHL.
IT_OUT-KBETR = ITAB1-KBETR.
IT_OUT-KWERT = ITAB1-KWERT.
APPEND IT_OUT.
ENDSELECT.
ENDIF.
ENDLOOP.
SORT IT_OUT BY KSCHL.
DELETE ADJACENT DUPLICATES FROM it_out COMPARING KSCHL.
LOOP AT IT_OUT.
IF
( IT_OUT-KSCHL = 'JADC'
OR IT_OUT-KSCHL = 'JCDB'
OR IT_OUT-KSCHL = 'JCV1'
OR IT_OUT-KSCHL = 'JECV'
OR IT_OUT-KSCHL = 'J1CV'
OR IT_OUT-KSCHL = 'JSDB'
OR IT_OUT-KSCHL = 'JEXC'
OR IT_OUT-KSCHL = 'JEXS'
OR IT_OUT-KSCHL = 'FRC1').
AT NEW KSCHL.
CLEAR out_par.
CLEAR out_par[].
LOOP AT OUT_PAR.
READ TABLE IT_OUT INDEX SY-TABIX.
SUM.
WRITE:/ IT_OUT-KSCHL,IT_OUT-VTEXT,IT_OUT-KBETR.
OUT_PAR-NAME = 'TYPE'.
OUT_PAR-VALUE = IT_OUT-KSCHL.
APPEND OUT_PAR.
OUT_PAR-NAME = 'TEXT'.
OUT_PAR-VALUE = IT_OUT-VTEXT.
APPEND OUT_PAR.
OUT_PAR-NAME = 'PER'.
OUT_PAR-VALUE = IT_OUT-KBETR.
APPEND OUT_PAR.
ENDLOOP.
ENDAT.
ENDIF.
ENDLOOP.
ENDIF.
ENDIF.
ENDFORM. "GET_TAX
Plz, help me by giving the solution...
Thanks,
AjitHi,
System will not display the Purchase order item details in the first screen. First enter the data on the Item overview like Material or short text then only it will display the Item details.
I think you are checking with out entering the data on Item overview .
Check by entering the material/short text.
rgds
Chidanand -
Problem in printing internal table data in Sapscript!
Hi All,
Am trying to print internal table data into main window of sapscript.
This is what I have written.
loop at it_final INTO wa_final.
CALL FUNCTION 'WRITE_FORM'
EXPORTING
window = 'MAIN'
ELEMENT = '670'
TYPE = 'BODY'
FUNCTION = 'APPEND'
EXCEPTIONS
window = 1
element = 2.
IF sy-subrc <> 0.
ENDIF.
ENDLOOP.
IN Sapscript :
/E 670
IT &wa_final-vbeln&,,&wa_final-vbelv&,,&wa_final-payment&
= &wa_final-rundate&,,&wa_final-waers&,,&wa_final-creditcard&
= &wa_final-augru&,,&wa_final-dmbtr&
Pls let me know if am missing anything.
Thanks & Regards
HimayatCheck if your Programm is called at the Sapscript level.
Are you calling the programm from the Sapscript using the PERFORM command? or are these Programm and Sapscript set in customizing?
Using SE16 check the Message Type and see if Sapscript and the programm are connected at all. -
How to draw the tables in sapscript?
Is there any other way then draw box for vetical and horizontal line.Hi
See this and draw the boxes in Script
SAPScripts
http://esnips.com/doc/1ff9f8e8-0a4c-42a7-8819-6e3ff9e7ab44/sapscripts.pdf
http://esnips.com/doc/1e487f0c-8009-4ae1-9f9c-c07bd953dbfa/script-command.pdf
http://esnips.com/doc/64d4eccb-e09b-48e1-9be9-e2818d73f074/faqss.pdf
http://esnips.com/doc/cb7e39b4-3161-437f-bfc6-21e6a50e1b39/sscript.pdf
http://esnips.com/doc/fced4d36-ba52-4df9-ab35-b3d194830bbf/symbols-in-scripts.pdf
http://esnips.com/doc/b57e8989-ccf0-40d0-8992-8183be831030/sapscript-how-to-calculate-totals-and-subtotals.htm
POSITION WINDOW
SIZE WIDTH '160' MM HEIGHT '140' MM
BOX FRAME 10 TW
Box
BOX HEIGHT '11' MM WIDTH '160' MM FRAME 10 TW INTENSITY 35
linessssssss
BOX XPOS '20' MM WIDTH 0 TW HEIGHT '140' MM FRAME 10 TW
BOX XPOS '45' MM WIDTH 0 TW HEIGHT '140' MM FRAME 10 TW
BOX XPOS '80' MM WIDTH 0 TW HEIGHT '140' MM FRAME 10 TW
BOX XPOS '120' MM WIDTH 0 TW HEIGHT '140' MM FRAME 10 TW
Boxes, Lines, Shading: BOX, POSITION, SIZE
Use the BOX, POSITION, and SIZE commands for drawing boxes, lines, and shading to print particular windows within a form or passages of text within a window in a frame or with shading.
The SAP printer drivers that are based on page-oriented printers (the HP LaserJet driver HPL2, the Postscript driver POST, the Kyocera Prescribe driver PRES) employ these commands when printing. Line printers and page-oriented printers not supported in the standard ignore these commands. You can view the resulting printer output in the SAPscript print preview.
Syntax:
/: BOX [XPOS] [YPOS] [WIDTH] [HEIGHT] [FRAME] [INTENSITY]
/: POSITION [XORIGIN] [YORIGIN] [WINDOW] [PAGE]
/: SIZE [WIDTH] [HEIGHT] [WINDOW] [PAGE]
BOX Command
Syntax
/: BOX [XPOS] [YPOS] [WIDTH] [HEIGHT] [FRAME] [INTENSITY]
Effect: draws a box of the specified size at the specified position.
Parameters: For each of XPOS, YPOS, WIDTH, HEIGHT, and FRAME, you must specify both a measurement and a unit of measurement. Specify the INTENSITY parameter as a percentage between 0 and 100.
XPOS, YPOS
Upper left corner of the box, relative to the values of the POSITION command.
Default: Values specified in the POSITION command.
The following calculation is performed internally to determine the absolute output position of a box on the page:
X(abs) = XORIGIN + XPOS
Y(abs) = YORIGIN + YPOS
WIDTH
Width of the box. Default: WIDTH value of the SIZE command.
HEIGHT
Height of the box. Default: HEIGHT value of the SIZE command.
FRAME
Thickness of frame.
Default: 0 (no frame).
INTENSITY
Grayscale of box contents as %.
Default: 100 (full black)
Measurements: You must specify decimal numbers as literal values (like ABAP numeric constants) by enclosing them in inverted commas. Use the period as the decimal point character. See also the examples listed below.
Units of measurement: The following units of measurement may be used:
TW (twip)
PT (point)
IN (inch)
MM (millimeter)
CM (centimeter)
LN (line)
CH (character).
The following conversion factors apply:
1 TW = 1/20 PT
1 PT = 1/72 IN
1 IN = 2.54 CM
1 CM = 10 MM
1 CH = height of a character relative to the CPI specification in the form header
1 LN = height of a line relative to the LPI specification in the form header
/: BOX FRAME 10 TW
Draws a frame around the current window with a frame thickness of 10 TW (= 0.5 PT).
/: BOX INTENSITY 10
Fills the window background with shading having a gray scale of 10 %.
/: BOX HEIGHT 0 TW FRAME 10 TW
Draws a horizontal line across the complete top edge of the window.
/: BOX WIDTH 0 TW FRAME 10 TW
Draws a vertical line along the complete height of the left hand edge of the window.
/: BOX WIDTH '17.5' CM HEIGHT 1 CM FRAME 10 TW INTENSITY 15
/: BOX WIDTH '17.5' CM HEIGHT '13.5' CM FRAME 10 TW
/: BOX XPOS '10.0' CM WIDTH 0 TW HEIGHT '13.5' CM FRAME 10 TW
/: BOX XPOS '13.5' CM WIDTH 0 TW HEIGHT '13.5' CM FRAME 10 TW
Draws two rectangles and two lines to construct a table of three columns with a highlighted heading section.
POSITION Command
Syntax
/: POSITION [XORIGIN] [YORIGIN] [WINDOW] [PAGE]
Effect: Sets the origin for the coordinate system used by the XPOS and YPOS parameters of the BOX command. When a window is first started, the POSITION value is set to refer to the upper left corner of the window (default setting).
Parameters: If a parameter value does not have a leading sign, then its value is interpreted as an absolute value, in other words, as a value that specifies an offset from the upper left corner of the output page. If a parameter value is specified with a leading sign, then the new value of the parameter is calculated relative to the old value. If one of the parameter specifications is missing, then no change is made to this parameter.
XORIGIN, YORIGIN
Origin of the coordinate system.
WINDOW
Sets the values for the left and upper edges to match those of the current window (default setting).
PAGE
Sets the values for the left and upper edges to match those of the current output page (XORIGIN = 0 cm, YORIGIN = 0 cm).
/: POSITION WINDOW
Sets the origin for the coordinate system to the upper left corner of the window.
/: POSITION XORIGIN 2 CM YORIGIN '2.5 CM'
Sets the origin for the coordinate system to a point 2 cm from the left edge and 2.5 cm from the upper edge of the output page.
/: POSITION XORIGIN '-1.5' CM YORIGIN -1 CM
Shifts the origin for the coordinates 1.5 cm to the left and 1 cm up.
SIZE Command
Syntax
/: SIZE [WIDTH] [HEIGHT] [WINDOW] [PAGE]
Effect: Sets the values of the WIDTH and HEIGHT parameters used in the BOX command. When a window is first started, the SIZE value is set to the same values as the window itself (default setting).
Parameters: If one of the parameter specifications is missing, then no change is made to the current value of this parameter. If a parameter value does not have a leading sign, then its value is interpreted as an absolute value. If a parameter value is specified with a leading sign, then the new value of the parameter is calculated relative to the old value.
WIDTH, HEIGHT
Dimensions of the rectangle or line.
WINDOW
Sets the values for the width and height to the values of the current window (default setting).
PAGE
Sets the values for the width and height to the values of the current output page.
/: SIZE WINDOW
Sets WIDTH and HEIGHT to the current window dimensions.
/: SIZE WIDTH '3.5' CM HEIGHT '7.6' CM
Sets WIDTH to 3.5 cm and HEIGHT to 7.6 cm.
/: POSITION WINDOW
/: POSITION XORIGIN -20 TW YORIGIN -20 TW
/: SIZE WIDTH +40 TW HEIGHT +40 TW
/: BOX FRAME 10 TW
A frame is added to the current window. The edges of the frame extend beyond the edges of the window itself, so as to avoid obscuring the leading and trailing text characters.
Reward points if useful
Regards
Anji -
Mapping data from internal table to SAPSCRIPT Box.
Hi Gurus,
I have to create a sapscript where in I should get data from standard tables and display the data in box (table format) in sapscript. I know how to get a field (perform in zprogram) into sapscript form zprogram. I dont know how I can get data (internal table) from my zprogram into sapscript and display in a box.
Your help is highly appreciated.Hi David,
consider the below example say if your zprogram having the internal table table loop and you want to print the contents line by line or in a box,
LOOP AT tj_1irg23d.
header line
CALL FUNCTION 'WRITE_FORM'
EXPORTING
element = 'ITEM_HEADER1'
EXCEPTIONS
OTHERS = 1.
endloop.
then in your sap script main window or where ever you want to print just straight away give your internal table fileds as follows(just for example)
I2 ,,&J_1IRG23D-ZEILE(Z)&,,&J_1IRG23D-MATNR&,,&J_1IRG23D-CHAPID&,,
= &J_1IRG23D-MENGE(Z)&,,&J_1IRG23D-MEINS&,,0.0,,
then it will bring the values of your internal table in the form. -
SapScript - Print table out_par - more than one entry for object
Hi Gurus,
following problem.
I have a SapScript form and call an external program from within the form.
In this programm I get more than one entry for the same out_par-value - this is correct.
My problem now is that on the form there is only printed one of the entrys.
Here my coding in SapScript.
/: DEFINE &ZZ_OBJECT& = ' '
/: PERFORM LESEN_OBJEKTLIST IN PROGRAM ZIHFORM
/: USING &CAUFVD-AUFNR&
/: CHANGING &ZZ_OBJECT&
/: ENDPERFORM
* All involved object:
* &ZZ_OBJECT&
Many thanks in advance for your help.
RegardsIn Sapscript PERFORM-ENDPERFORM statements, the parameters can contain only one value as they are variables of type character & length 80.
If you want multiple values in your CHANGING parameters, fetch all of them in different variables. Also, in your program store them in the same order, in the output internal table of structure ITCSY.
Check this thread
http://wiki.sdn.sap.com/wiki/display/profile/ExternalSubroutinesinSAPScript -
How to Draw table in SAPscript ???
Hi all Guru of SAPScript!
I want to draw a table with column and row in SAPscript. Who can help me step by step?
Thanks!
Edited by: kathy a on May 6, 2008 11:53 AMHi,
Use BOx Syantax How to Draw table in SAPscript ??? Pls Read the description
Syntax:
1. /: BOX [XPOS] [YPOS] [WIDTH] [HEIGHT] [FRAME] [INTENSITY]
2. /: POSITION [XORIGIN] [YORIGIN] [WINDOW] [PAGE]
3. /: SIZE [WIDTH] [HEIGHT] [WINDOW] [PAGE]
BOX
Syntax:
/: BOX [XPOS] [YPOS] [WIDTH] [HEIGHT] [FRAME] [INTENSITY]
Effect: draws a box of the specified size at the specified position.
Parameters: For each parameter (XPOS, YPOS, WIDTH, HEIGHT and FRAME), both a measurement and a unit of measure must be specified. The INTENSITY parameter should be entered as a percentage between 0 and 100.
XPOS, YPOS: Upper left corner of the box, relative to the values of the POSITION command.
Default: Values specified in the POSITION command.
The following calculation is performed internally to determine the absolute output position of a box on the page:
X(abs) = XORIGIN + XPOS
Y(abs) = YORIGIN + YPOS
WIDTH: Width of the box.
Default: WIDTH value of the SIZE command.
HEIGHT: Height of the box.
Default: HEIGHT value of the SIZE command.
FRAME: Thickness of frame.
Default: 0 (no frame).
INTENSITY: Grayscale of box contents as %.
Default: 100 (full black)
Measurements: Decimal numbers must be specified as literal values (like ABAP/4 numeric constants) by being enclosed in inverted commas. The period should be used as the decimal point character. See also the examples listed below.
Units of measure: The following units of measure may be used:
TW (twip)
PT (point)
IN (inch)
MM (millimeter)
CM (centimeter)
LN (line)
CH (character).
The following conversion factors apply:
1 TW = 1/20 PT
1 PT = 1/72 IN
1 IN = 2.54 CM
1 CM = 10 MM
1 CH = height of a character relative to the CPI specification in the layout set header
1 LN = height of a line relative to the LPI specification in the layout set header
Examples:
/: BOX FRAME 10 TW
Draws a frame around the current window with a frame thickness of 10 TW (= 0.5 PT).
/: BOX INTENSITY 10
Fills the window background with shadowing having a gray scale of 10 %.
/: BOX HEIGHT 0 TW FRAME 10 TW
Draws a horizontal line across the complete top edge of the window.
/: BOX WIDTH 0 TW FRAME 10 TW
Draws a vertical line along the complete height of the left hand edge of the window.
/: BOX WIDTH '17.5' CM HEIGHT 1 CM FRAME 10 TW INTENSITY 15
/: BOX WIDTH '17.5' CM HEIGHT '13.5' CM FRAME 10 TW
/: BOX XPOS '10.0' CM WIDTH 0 TW HEIGHT '13.5' CM FRAME 10 TW
/: BOX XPOS '13.5' CM WIDTH 0 TW HEIGHT '13.5' CM FRAME 10 TW
Draws two rectangles and two lines to construct a table of three columns with a highlighted heading section.
POSITION
Syntax:
/: POSITION [XORIGIN] [YORIGIN] [WINDOW] [PAGE]
Effect: Sets the origin for the coordinate system used by the XPOS and YPOS parameters of the BOX command. When a window is first started the POSITION value is set to refer to the upper left corner of the window (default setting).
Parameters: If a parameter value does not have a leading sign, then its value is interpreted as an absolute value, in other words as a value which specifies an offset from the upper left corner of the output page. If a parameter value is specified with a leading sign, then the new value of the parameter is calculated relative to the old value. If one of the parameter specifications is missing, then no change is made to this parameter.
XORIGIN, YORIGIN: Origin of the coordinate system.
WINDOW: Sets the values for the left and upper edges to be the same of those of the current window (default setting).
PAGE: Sets the values for the left and upper edges to be the same as those of the current output page (XORIGIN = 0 cm, YORIGIN = 0 cm).
Examples:
/: POSITION WINDOW
Sets the origin for the coordinate system to the upper left corner of the window.
/: POSITION XORIGIN 2 CM YORIGIN '2.5 CM'
Sets the origin for the coordinate system to a point 2 cm from the left edge and 2.5 cm from the upper edge of the output page.
/: POSITION XORIGIN '-1.5' CM YORIGIN -1 CM
Shifts the origin for the coordinates 1.5 cm to the left and 1 cm up.
SIZE
Syntax:
/: SIZE [WIDTH] [HEIGHT] [WINDOW] [PAGE]
Effect: Sets the values of the WIDTH and HEIGHT parameters used in the BOX command. When a window is first started the SIZE value is set to the same values as the window itself (default setting).
Parameters: If one of the parameter specifications is missing, then no change is made to the current value of this parameter. If a parameter value does not have a leading sign, then its value is interpreted as an absolute value. If a parameter value is specified with a leading sign, then the new value of the parameter is calculated relative to the old value.
WIDTH, HEIGHT: Dimensions of the rectangle or line.
WINDOW: Sets the values for the width and height to the values of the current window (default setting).
PAGE: Sets the values for the width and height to the values of the current output page.
Examples:
/: SIZE WINDOW
Sets WIDTH and HEIGHT to the current window dimensions.
/: SIZE WIDTH '3.5' CM HEIGHT '7.6' CM
Sets WIDTH to 3.5 cm and HEIGHT to 7.6 cm.
/: POSITION WINDOW
/: POSITION XORIGIN -20 TW YORIGIN -20 TW
/: SIZE WIDTH +40 TW HEIGHT +40 TW
/: BOX FRAME 10 TW
A frame is added to the current window. The edges of the frame extend beyond the edges of the window itself, so as to avoid obscuring the leading and trailing text characters.
Reward Helpfull Answers
Regards
Fareedas -
How to psss a table from sapscript to routine program
HI,
i want to pass a table from sapscript to routine program.
the requirment is to sor the table by material number wise.
how do we pass throug itcsy structure.
Regards,
BalachandranREPORT YMMR_TDS_LPRG .
TABLES: ADRC."Central address administration
FORM FETCH_VEN_ADD *
--> IN_TAB *
--> OUT_TAB *
FORM FETCH_VEN_ADD TABLES IN_TAB STRUCTURE ITCSY
OUT_TAB STRUCTURE ITCSY.
DATA: L_STREET4 LIKE ADRC-CITY2,
L_STREET5 LIKE ADRC-LOCATION,
L_INDEX1 LIKE SY-TABIX.
DATA: LEN TYPE I.
DATA: Z1(5) VALUE '00000'.
LEN = STRLEN( IN_TAB-VALUE ).
IF LEN = 5.
CONCATENATE '00000' IN_TAB-VALUE INTO IN_TAB-VALUE.
ELSEIF LEN = 6.
CONCATENATE '0000' IN_TAB-VALUE INTO IN_TAB-VALUE.
ENDIF.
SELECT CITY2 LOCATION FROM ADRC
INTO (L_STREET4,L_STREET5)
WHERE ADDRNUMBER = IN_TAB-VALUE.
IF SY-SUBRC = 0.
LOOP AT OUT_TAB.
CLEAR L_INDEX1.
IF OUT_TAB-NAME = 'ADRC-CITY2'.
L_INDEX1 = SY-TABIX.
OUT_TAB-VALUE = L_STREET4.
MODIFY OUT_TAB INDEX L_INDEX1 TRANSPORTING VALUE.
ELSE.
L_INDEX1 = SY-TABIX.
OUT_TAB-VALUE = L_STREET5.
MODIFY OUT_TAB INDEX L_INDEX1 TRANSPORTING VALUE.
ENDIF.
ENDLOOP.
ENDIF.
ENDSELECT.
ENDFORM.
Se71
/:PERFORM FETCH_VEN_ADD IN PROGRAM YMMR_TDS_LPRG
/:USING &T001-ADRNR&
/:CHANGING &ADRC-CITY2&
/:CHANGING &ADRC-LOCATION&
/:ENDPERFORM -
Passing Internal table to SAPscript from report
Hi Experts..
I have a requirement of sending Rate Change notification to the business partner and the code of which is written in SAPscript
I've written the query part in driver program but I am unable to send the vkonto(Contract Account) which is in internal table(IT_EVER) to the SAPscript, though I am using OPEN_FORM, WRITE_FORM and CLOSE_FORM function modules, but still I am unable to get the values in SAPscript.. I unable to pass IT_EVER to SAPscript..
SELECT-OPTIONS: S_VKONT FOR FKKVKP-VKONT MODIF ID TT. " Contract Account Number
SELECT VERTRAG ANLAGE VKONTO INTO TABLE IT_EVER FROM EVER WHERE VKONTO IN S_VKONT.
CALL FUNCTION 'OPEN_FORM'
EXPORTING
APPLICATION = 'TX' " Standard Text
ARCHIVE_INDEX =
ARCHIVE_PARAMS =
DEVICE = 'PRINTER'
DIALOG = 'X'
FORM = ' '
LANGUAGE = SY-LANGU
OPTIONS =
MAIL_SENDER =
MAIL_RECIPIENT =
MAIL_APPL_OBJECT =
RAW_DATA_INTERFACE = '*'
SPONUMIV =
IMPORTING
LANGUAGE =
NEW_ARCHIVE_PARAMS =
RESULT =
EXCEPTIONS
CANCELED = 1
DEVICE = 2
FORM = 3
OPTIONS = 4
UNCLOSED = 5
MAIL_OPTIONS = 6
ARCHIVE_ERROR = 7
INVALID_FAX_NUMBER = 8
MORE_PARAMS_NEEDED_IN_BATCH = 9
SPOOL_ERROR = 10
CODEPAGE = 11
OTHERS = 12
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
CALL FUNCTION 'WRITE_FORM'
EXPORTING
ELEMENT = ' '
FUNCTION = 'SET'
TYPE = 'BODY'
WINDOW = 'MAIN'
IMPORTING
PENDING_LINES =
EXCEPTIONS
ELEMENT = 1
FUNCTION = 2
TYPE = 3
UNOPENED = 4
UNSTARTED = 5
WINDOW = 6
BAD_PAGEFORMAT_FOR_PRINT = 7
SPOOL_ERROR = 8
CODEPAGE = 9
OTHERS = 10
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
CALL FUNCTION 'CLOSE_FORM'
IMPORTING
RESULT =
RDI_RESULT =
TABLES
OTFDATA =
EXCEPTIONS
UNOPENED = 1
BAD_PAGEFORMAT_FOR_PRINT = 2
SEND_ERROR = 3
SPOOL_ERROR = 4
CODEPAGE = 5
OTHERS = 6
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.but where do i have to write the SAPscript's name in the function module? And where do I have to write IT_EVER internal table which I want to pass to SAPscript..
CALL FUNCTION 'OPEN_FORM'
EXPORTING
APPLICATION = 'TX' " Standard Text
ARCHIVE_INDEX =
ARCHIVE_PARAMS =
DEVICE = 'PRINTER'
DIALOG = 'X'
FORM = ' '
LANGUAGE = SY-LANGU
OPTIONS =
MAIL_SENDER =
MAIL_RECIPIENT =
MAIL_APPL_OBJECT =
RAW_DATA_INTERFACE = '*'
SPONUMIV =
IMPORTING
LANGUAGE =
NEW_ARCHIVE_PARAMS =
RESULT =
EXCEPTIONS
CANCELED = 1
DEVICE = 2
FORM = 3
OPTIONS = 4
UNCLOSED = 5
MAIL_OPTIONS = 6
ARCHIVE_ERROR = 7
INVALID_FAX_NUMBER = 8
MORE_PARAMS_NEEDED_IN_BATCH = 9
SPOOL_ERROR = 10
CODEPAGE = 11
OTHERS = 12
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
LOOP AT IT_EVER INTO WA_EVER.
CALL FUNCTION 'WRITE_FORM'
EXPORTING
ELEMENT = ' '
FUNCTION = 'SET'
TYPE = 'BODY'
WINDOW = 'MAIN'
IMPORTING
PENDING_LINES =
EXCEPTIONS
ELEMENT = 1
FUNCTION = 2
TYPE = 3
UNOPENED = 4
UNSTARTED = 5
WINDOW = 6
BAD_PAGEFORMAT_FOR_PRINT = 7
SPOOL_ERROR = 8
CODEPAGE = 9
OTHERS = 10
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ENDLOOP.
CALL FUNCTION 'CLOSE_FORM'
IMPORTING
RESULT =
RDI_RESULT =
TABLES
OTFDATA =
EXCEPTIONS
UNOPENED = 1
BAD_PAGEFORMAT_FOR_PRINT = 2
SEND_ERROR = 3
SPOOL_ERROR = 4
CODEPAGE = 5
OTHERS = 6
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
Maybe you are looking for
-
Filling up a variable value from another variable
Hi, I have two date fields, one calmonth characteristic ZCALMON (as char) and other calmonth charactaeristic 0CALMON as time dimension (standard bw). But at query level, I would like to user enter only one variable value 0PCALMON for 0CALMON (say onl
-
Just got a mental blank. I am creating a flash cd that will contain an image gallery. Once a person has selected the image file I want them to be able to download that file to their computer. The final SWF and images will be contained within the same
-
How to trigger the BPM process from WD Application
Hello All, I have a simple business process with two ui activities. I am able to start the process from NWA -> Process Repository. But, I need to start the process from the application. Here is the requirement: User opens the application. ON completi
-
Uploading many text file into many table
hi there, my problem is that i have lots of text files (about 360 files), what i need is to upload them to many tables already created in oracle, as far as i know, i can upload only one file per command using the SQL loader, any help would be appreci
-
Hi, I am done with the Xquery Mapper and have got an .xq file as an output. This .xq file takes an .xml as an input converts as defined in the Xquery tool. I have gone ahead and loaded this .xq file in the Aqualogic, which has provided with the funct