1
votes

I am using in-app billing and I would like to log the purchases into Google Analytics e-commerce:

  • the in-app billing provides the price in the "number symbol" format (e.g. "1.99 €"), from where I can get the currency symbol (e.g. "€", "£")
  • Google Analytics e-commerce needs the currency code (e.g. "EUR", "GBP")

how can I convert the currency symbol into the currency code?

1

1 Answers

1
votes

I am not sure whether you explored Currency in util. If not, please try http://developer.android.com/reference/java/util/Currency.html