Dynamics CRM 2011: Multiple Exchange Rates for Currencies

Having Dynamics CRM 2011 is limited to a single Exchange Rate per currency which leaves a lot of head-scratching for many.  Rarely does a single exchange rate capture the complexities of multi-currency environments.  We, here at Rockton Software, wanted to be able to change our exchange rates by date, have a date-driven table to pull rates from, and have a given transactions pull the correct rate by date.

I searched high and low around the internet and found little information, just others having similar issues and frustrations.  I finally opened a support case with Microsoft to see if their team would “hack” CRM source code to get us to a solution.  I was lucky to find a developer inside of Microsoft that stumbled on an idea to write a plugin against a system message.  It turns out that Microsoft had vision on this issue and exposed a public message for CRM developers called RetrieveExchangeRate that acts on the TransactionCurrency object.

Not knowing how to write a plugin myself, one of our talented developers found this CRM message and was able to write a plugin against it.  Sure enough, there’s adequate information available to route a call for an Exchange Rate to our own custom table, look up a Rate by Date, and return what we want.  The cool part is that CRM still does the math for us, calculating the Base amount for money fields and rounding as necessary.

What I found funny about this project is that the SDK team at Microsoft actually completed a project with this same scope, in all its glorious detail, for CRM version 4.0.  It’s available if you search on the right keywords for it.  Even though Microsoft support published it, few at Microsoft know it exists.

 Have you heard about Rockton's upcoming CRM offering? Rockton Connect, Making Business Visible.

 Written By Mark Rockwell, President of Rockton Software.

2 thoughts on “Dynamics CRM 2011: Multiple Exchange Rates for Currencies”

  1. Like I said above in my closing paragraph, this code is hard to find. Turns out after over an hour of searching I cannot find it again. We did test this plugin methodology back when I first wrote this blog, and I can assure you it worked. You have to register a plugin on the RetrieveExchangeRate Message and then alter the results you get back. If you have experience with plugins, this should make sense. If you do not have experience with plugins, you’ll need a developer to assist with this.

    In our project we will be writing this code in about another year.

Comments are closed.

Show Buttons
Hide Buttons