P peter93 Member Licensed User Longtime User Sep 29, 2019 #1 I would like to retrieve the symbol of the currency being used on the device (by default?) I found a java class that is 'java.util.Currency' with a method called 'String getSymbol()'. but not knowing Java, I can't write the function correctly for B4A. Could someone help me?
I would like to retrieve the symbol of the currency being used on the device (by default?) I found a java class that is 'java.util.Currency' with a method called 'String getSymbol()'. but not knowing Java, I can't write the function correctly for B4A. Could someone help me?
DonManfred Expert Licensed User Longtime User Sep 29, 2019 #2 Try this library. Samplecode Code: Dim chlp As CurrencyHelper chlp.Initialize("GBP") Log($"${chlp.DisplayName}"$) Log($"${chlp.Symbol}"$) Output Code: *** Service (starter) Create *** ** Service (starter) Start ** ** Activity (main) Create, isFirst = true ** Britisches Pfund £ ** Activity (main) Resume ** ** Activity (main) Pause, UserClosed = false ** ** Activity (main) Resume ** Note that i am german and i get the german version of the Displayname Attachments CurrencyHelperV0.01.zip CurrencyHelperV0.01.zip 1.4 KB · Views: 438 Upvote 0
Try this library. Samplecode Code: Dim chlp As CurrencyHelper chlp.Initialize("GBP") Log($"${chlp.DisplayName}"$) Log($"${chlp.Symbol}"$) Output Code: *** Service (starter) Create *** ** Service (starter) Start ** ** Activity (main) Create, isFirst = true ** Britisches Pfund £ ** Activity (main) Resume ** ** Activity (main) Pause, UserClosed = false ** ** Activity (main) Resume ** Note that i am german and i get the german version of the Displayname
P peter93 Member Licensed User Longtime User Sep 30, 2019 #3 Works well. Thank you DonManfred. Upvote 0