I Can't Write Arabic text in the XAML file

后端 未结 3 2004
生来不讨喜
生来不讨喜 2021-01-18 19:19

when i built the project the following error happened:

相关标签:
3条回答
  • 2021-01-18 19:25

    Change the XAML file encoding to "UTF-8" , you can use Visual Studio to Save File As and then change the encoding.

    0 讨论(0)
  • 2021-01-18 19:39

    To Change the encoding try this

    var pi = xmldoc.createProcessingInstruction("xml",
                                    " version='1.0' encoding='UTF-8'");
    xmldoc.appendChild(pi);
    

    Check out the link below. http://msdn.microsoft.com/en-us/library/aa468560.aspx

    0 讨论(0)
  • 2021-01-18 19:42

    The problem is clear, you have a problem with your file encoding, If am not mistaken the word in the Text property up there is an Arabic keyword which requires Unicode encoding. Change your file encoding to Unicode, by doing the following:

    Open the XAML file you have problem with, go to File > Save As

    enter image description here

    Click on the small down arrow at the save button to select the encoding

    enter image description here

    Select Unicode save and replace your old file.

    enter image description here

    This should solve your problem.

    0 讨论(0)
提交回复
热议问题