0

I have a strings.xml file with all my app string, I have some simbols like €, and I having trouble with them.

<?xml version="1.0" encoding="utf-8"?>
<resources>
     <string name="currency"> € </string>
</resources></resources>

They usually shows fine, but not in all devices:

enter image description here

How can I auto-detect the configuration in the device?

3 Answers 3

1

You can create string files for different languages. Please read "Supporting Different Languages".

Sign up to request clarification or add additional context in comments.

Comments

1

I found the problem, in the java class I had:

 webCost.loadData(cost, "text/html", null);

And it should be:

  webAbout.loadDataWithBaseURL(null, aboutStr, "text/html","utf-8", null);

Comments

1

You should use Unicode Character for Currency symbol.

so instead of

<string name="currency"> € </string>

use this one

 <string name="pound">\u00a3</string>
 <string name="euro">\u20ac</string>

This will uni formally look same in all the devices. This will surely solve your issue.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.