01-09-2015 10:59 AM
Hi,
my requirement is in script form , if foreign currency is used in input i want add two new columns in layout with local currency Per Unti Price and Total Amount of local currency script is related Tax Invoice , Debit and Credit Note.
if local currency is used then only three columns are appeared those are Quantity , PerUnitPrice and Total Amount
Please help me.
01-09-2015 11:09 AM
Hi
You need to create 2 different text element: one for local currency and one for foreign currency
Mac
01-10-2015 6:35 AM
Hi Max,
Thanks to replay,
step1: i have one window like Header to display Heading details those are Description and Price.
now i want display Headings based on condition
IF BKPF-WAERS NE 'MYR'.
Description Quantity Per Unit Price(USD) Per Unit Price(RM) Total(USD) Total/Price(RM)
ELSE
Description Quantity Per Unit Price Total/Price
step2 :
on same currency condition i want dispaly values under whcih is i given above headings
present Description Total/Price are printing.
If foreign currency is used then i want display Local currency Total and Per Unit Price.
Per Unit Price = Quantity/Amount
Total(RM) = USD Total * Exchange Rate
Exchange Rate printing some where else .
My question is can i print values based on currency condition in MAIN Window.
If possible give me some sample examples
Reward for all helpfull answers
01-12-2015 11:48 AM
Hi
You can use the fm WRITE_FORM in order to trigger a certain text element of the MAIN:
/E LOCAL_HEADER
* Description Quantity Per Unit Price(USD) Per Unit Price(RM) Total(USD) Total/Price(RM)
/E FOREIGN_HEADER
* Description Quantity Per Unit Price Total/Pric
So in your program you should insert the following check:
IF BKPF-WAERS = T001-WAERS.
CALL FUNCTION 'WRITE_FORM'
EXPORTING
ELEMENT = 'LOCAL_HEADER'
FUNCTION = 'SET'
TYPE = 'BODY'
WINDOW = 'MAIN'.
ELSE.
CALL FUNCTION 'WRITE_FORM'
EXPORTING
ELEMENT = 'FOREIGN_HEADER'
FUNCTION = 'SET'
TYPE = 'BODY'
WINDOW = 'MAIN'.
ENDIF.
Or you can insert the control in your form:
/E HEADER
/: IF &BKPF-WAERS& = &T001-WAERS&
* Description Quantity Per Unit Price(USD) Per Unit Price(RM) Total(USD) Total/Price(RM)
/: ELSE
* Description Quantity Per Unit Price Total/Pric
/: ENDIF
01-12-2015 12:22 PM
01-18-2015 10:46 AM
Hi Max,
Your replay very useful to me.
Thanks for this,
Let me know one thing , i am getting values in different Text Elements, but i want display in same line ,
Ex:
Description Quantity PerUnitPrice
Test Data 100 PC 10000
Ex Code:
/:500
&gv_tdline_new&
/: 501
&bseg-menge&
/:502
&wa_itab-uprice&
Here i want display in same line of above printed lines , is is possible.
If possible please give sample example
01-18-2015 10:56 AM
Hi Anand,
You can display all texts in 1 line.
&gv_tdline_new&,,&bseg-menge&,,&wa_itab-uprice&
Here, ',,' stands for tab. So, it will display your data as below:
Test Data 100 PC 10000
01-20-2015 1:27 PM
Hi
you should create a text element for local currency and one for foreign currency:
Ex:
Description Quantity PerUnitPrice
Test Data 100 PC 10000
Ex Code:
/:500
&gv_tdline_new&
/: 501
&bseg-menge&
/:502
&wa_itab-uprice&
so you should have:
/:500 &gv_tdline_new& &bseg-menge& &wa_itab-uprice&
Max
01-24-2015 12:55 PM