How to display double quotes(") Symbol in a TextView?

后端 未结 9 908
天涯浪人
天涯浪人 2020-12-05 01:27

I\'m trying to display some words in double quotes, in Text view in in xml file. But its not working. Pls help me.

    

        
9条回答
  •  广开言路
    2020-12-05 02:15

    If you have a double-quote in your string, you must escape it (\"). Surrounding the string with single-quotes does not work.

    In strings.xml

    This is a \"good string\".
    

    Source :http://developer.android.com/guide/topics/resources/string-resource.html

提交回复
热议问题