Karlo Kraljic
Karlo Kraljic

Reputation: 173

Excel sets wrong currency after explicit numberFormat conversion

I have the following line(s) of code:

With new_pivot_table.PivotFields( _
    "Count of Weighted Parameter")
    .Caption = "Sum of Weighted Parameter"
    .Function = xlSum
    .NumberFormat = "$ #,##0.00"
End With

But my Excel sheet displays the currencies in €. Why is Excel showing € instead of $? Does the currency depend on the location where I am currently sitting (i.e. set by any Windows services automatically) or is my syntax wrong? How can I enforce that this column(s) are displayed in $$?

Thank you in advance.

Upvotes: 0

Views: 606

Answers (1)

Tilan04
Tilan04

Reputation: 86

I find this little tutorial for change the currencies to Euros. I suppose that is the same method to change to Dollars.

http://www.howtogeek.com/240216/how-to-change-windows-default-currency-from-dollars-to-euros/

Follow this steps (Only in Windows):

  • Search "Change the way currency is displayed"
  • Click on "Additional settings".
  • Select "Currency" tab.
  • Select the currency symbol that you want in "Currency symbol" list.
  • Apply the changes.

Upvotes: 2

Related Questions