Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在尝试Text使用包含变音符号的字符串在 WPF 中设置文本框的属性:
Text
Textbox.Text = "!@#$%&*,ÖÄäü";
但文本框仅显示!@#$%&*,和省略变音符号。
!@#$%&*,
如何使变音符号出现?
您可以尝试使用Unicode (UTF-8 with signature) - Codepage 65001编码保存文件(文件->另存为->在 Visual Studio 中使用编码保存)或Character Map在 Windows 的应用程序中查找字符的 unicode。
Unicode (UTF-8 with signature) - Codepage 65001
Character Map
对于ü,00FC例如:
ü
00FC
Textbox.Text = "\u00FC";