function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Nani44Nani44 

Currency field is displayed wrongly

Hi All,

when a button is clicked then  I need to sum the existing muliple currency field populate that value in another currenct field. For that in query I am using convertCurrency for that field. upto here everthing is working fine. But when the user changes his currency from USD to another currency in the user oject and refreshes the page where the button is residing then target currency field shows correct converted currecny. after that if the user hits the button then the target fields shows wrongly. when i check the debug logs it is inserting right value but salesforce is displaying worngly .

For example:Actual : Before changing the currency  at user level which USD 
                                 target field value: 1,922,975.37(initially the record is created in INR)
                  after  changing the currency  at user level to Indian Rupee
                            traget field value :INR 119,076,405.03 (USD 1,922,975.39)
                   after hiting button the currency field is shown like this 
                                      traget field value :  INR 1,922,975.37 (USD 31,054.30)
     
Thanks.      
Ashish_SFDCAshish_SFDC
Hi , 


If you have a custom currency__c (picklist?) reports aren't aware of that. All fields of type "Currency" will continue to be displayed with record's "true" currency (CurrencyIsoCode field). This behavior is consistent on standard page layouts, VF pages (as long as <apex:outputField> was used and on reports so I doubt you've realized it only when you reached the point of making reports.

If you see "AED 0.64" it means CurrencyIsoCode is AED. You can flip the report to € using Show (menu bar next to where you select charts) -> Currencies using -> EUR. This will however convert values using your current exchange rates. And you'll have to drop to the report "My Currency Field (converted)" instead of regular "My Currency Field").

If you want "raw" values - store them in a field of type Number and not Currency? You won't be able to change type of standard fields though...

I don't think we can help you more without knowing why you decided yo need a custom currency field and why you didn't explore limitations like that.


http://stackoverflow.com/questions/15102054/sfdc-report-showing-wrong-currency


Regards,
Ashish