UMAR-MOBITSOLUTIONS
UMAR-MOBITSOLUTIONS

Reputation: 78004

android does not display "" inside TextView?

i am trying to display STRING my car name is "abc" in textview.

it displays &qoute;abc&qoute; after running application.

i have tried decoding into " and then assigning it to TextView but it always convert " to &qoute;

can any one guide me how to solve this issue?

any help would be appriciated.

Upvotes: 1

Views: 483

Answers (3)

R. Zagórski
R. Zagórski

Reputation: 20268

For me none of the solutions presented here earlier did not worked.

Sharing my method to do this:

<string name="filter">\&quot;Filtruj\&quot;</string>

Upvotes: 0

Samuh
Samuh

Reputation: 36484

Escape them; use &quot; to have quotes in XML values.
For e.g. try: android:text="&quot; hi &quot;"

Upvotes: 2

Macarse
Macarse

Reputation: 93173

I have done it escaping the "

Example:

<string name="pref_about_text">Estado del Tránsito versión \"%s\"\nCreado por:</string>

Upvotes: 2

Related Questions