on 08-26-2010 4:15 PM
Hi,
can you please tell me what is the process for converting the currency in below format.
if amount is 2,000.34(INR--Two thousand rupees 34 Paise).This should be displayed like 2.000,34.
Inplace of commas dots should be appeared and vice versa.
Thanks and Regards,
K.krishna .
answered
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello ,
try like this ...
data l_amount c(20) type c.
write amount into l_amount currency 'INR'. "it will take of curreny decimal format and user notation as well.
regards
Prabhu
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Use abap set country to change the format.
Otherwise do a simple logic:-
(Using string type) replace all '.' with "," and vice versa.
hope it helps.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Use below FM by specifying the required format:
CALL FUNCTION 'HRGPBS_HER_FORMAT_AMOUNT'
EXPORTING
P_AMOUNT = G_MAXBT
P_CURRENCY = G_WAERS
P_REQUIRED_FORMAT = '9.99.999,99'
IMPORTING
P_ERROR = L_ERROR_DURING_FORMAT
P_ERROR_AMOUNT = L_ERROR_AMOUNT
P_ERROR_CURRENCY = L_ERROR_CURRENCY
P_ERROR_OVERFLOW = L_ERROR_OVERFLOW
CHANGING
P_FORMATTED_AMOUNT = G_RWBTR.
IF L_ERROR_DURING_FORMAT NE 0.
IF L_ERROR_DURING_FORMAT = 1.
MESSAGE E002 WITH 'Error during currency format conversion'.
ELSE.
MESSAGE E002 WITH 'Error during currency format conversion'.
ENDIF.
ENDIF.
Thanks and Regards
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Krishan,
Why not your use user profile and set as your desire currency format.
Regards,
Syed Tayab Shah
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
You can use the ABAP SET COUNTRY to set to the desired format at the start of the document window (MAIN) as described in SAP Note #32105.
Regards,
Aidan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
93 | |
11 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.