09-10-2009 7:47 AM
Hi Abapers,
I have developed a FM which is used for sending SMS
Now my Problem is that to send sms i have converted the amount field into string
But the requirement is such that where if suppose
5000 how can i insert comma there, as the values are dynamic
it can be 25000 it can be any thing and accordingly the comma has to be adjusted
Because of which i cant even define particular position where the comma has to be inserted
as the values are dynamic,
Is there any way to solve this problem...?
09-10-2009 8:11 AM
You will get a idea with this
DATA : value TYPE i ,
out type char255.
value = '12345'.
write value to out.
condense out.
write out.
in your case move 'out' to your string
Here the separators will be placed as of your user profile settings.
09-10-2009 8:07 AM
Hi,
You can use the following Function Modules
BAPI_CURRENCY_CONV_TO_EXTERNAL
Just enter the type of currency you want and the amount which is converted into string
Regards,
Harini.S
09-10-2009 8:08 AM
Thanks for ur reply,
But this is like coming back to where i started from as i have already mentioned that
i have converted the amount field to string
The FM u gave me will again convert the string into currency type
Edited by: Aarif Baig on Sep 10, 2009 12:39 PM
Edited by: Aarif Baig on Sep 10, 2009 12:40 PM
09-10-2009 8:19 AM
Hi,
You have to mention the string value in the function module,which in turn will return the value with '.' and ','.Otherwise send me your code i will help you.
Regards,
Harini.S
09-10-2009 8:11 AM
You will get a idea with this
DATA : value TYPE i ,
out type char255.
value = '12345'.
write value to out.
condense out.
write out.
in your case move 'out' to your string
Here the separators will be placed as of your user profile settings.
09-10-2009 8:25 AM