gpt4 book ai didi

android - 如何在 string.xml 中为 android 创建@symbol

转载 作者:行者123 更新时间:2023-11-29 21:38:54 25 4
gpt4 key购买 nike

我正在尝试在我的 android 应用程序中创建@sancorporation。我已经在 string.xml 中编写了字符串,例如 "<"string name="cor_name">sancorporation"<"/string>,但我需要这样的东西 "<"string name="cor_name">@sancorporation"<"/string >。 android中如何取特殊符号?

最佳答案

使用@symble 的ascii 值是0040 所以试试

@sancorporation

          <string name="mytest">&#64;sancorporation</string>

or
<string name="mytest">\u0040 sancorporation</string>

关于android - 如何在 string.xml 中为 android 创建@symbol,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/17640284/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com