Sage CRM Currency Conversion through code

By | August 21, 2014

Every country has its own Currency. Businesses that sell products in different territories may need to capture all those currencies as well. Also they may want to see the reports in their own currency as base.
New Stuff: Limit number of characters in Sage CRM fields
In Sage CRM we can configure multiple currencies, conversion Rate as well as Base Currency. Also the currency field values are properly displayed accordingly.
Currency Setting
In case you have any other field and you want to do the conversion to different currency through code, it can also be done. Here is the syntax. This script can be put on CreateScript of the field or any server side code we write for building pages.
CRM.ConvertValue(numFromValue, numFromCurr,numToCurr)*1
For this method you need provide below given 3 parameters
numFromValue :- Value to be converted
numFromCurr :- Currency id for currency from which we are converting
numToCurr:- Currency Id for currency to which we are converting