Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

BADI for currency conversion!!! Request help ASAP

Former Member
0 Likes
1,333

Hi friends,

We are having currency data in copa from pacific, canada,europe and even america...we need to use a BADI in a particular scenario where we can convert all currencies to USD....please help me with the code for the same..or is there any standar SAP provide method for the same

...this is urgent..request help soon

Hi friends,

We are having currency data in copa from pacific, canada,europe and even america...we need to use a BADI in a particular scenario where we can convert all currencies to USD....please help me with the code for the same..or is there any standar SAP provide method for the same

...this is urgent..request help soon

4 REPLIES 4
Read only

Former Member
0 Likes
984

Hi Andy,

Call the function module: CONVERT_AMOUNT_TO_CURRENCY inside your BADI.

That will do the trick.

Brad

Read only

0 Likes
984

Here is a code sample you can use:

Brad

Read only

0 Likes
984

hi brad,

Thanks a lot for the immediate reply ,

I am a BW guy.. and when i looked at the code i understood the code but did not understand why the foreign_amount = '2000.00' is it the exchange rate or can we automate it to take values automatically by anyways and another main thing is this sample code with any type of situation in the sense does it work with COPA data

Read only

0 Likes
984

Hi Andy,

The foreign amount is hard coded in this example, you jsut need to substitute your variable instead of '2000.00'.

As for COPA, yes this will work for any data where you have a value, a currency, and a currency to change it to.

I would recommend, however, that you get an ABAP savvy person to help with the BADI implementation, just to be sure that its all implemented correctly.

Cheers,

Brad