How to get currency symbol from currency code?

Hey guys,

Currently i am writing test cases on my project, so i want currency symbol in katalon.
is there any code, that is give me currency symbol when i pass currency code as parameter.

Hey Mihir,

java.util.Currency class may help you.

println Currency.getInstance("USD").getSymbol()// output$
1 Like

Hey Marek_Melocik, this is not returning for all currencies like GBP, IND, etc.
is it only return for USD?

It seems your question has been asked on a lot of other sites too. Try:

And as a Groovy library as well (note the bit about passing in the locale you want):

And locales: