I have a C# file that has some arabic text in it, I got the file from another source, the arabic text is now scrambled. looking like this (“ÇáãæÇÞÚ ÇáÞÇÈáÉ ááÊØæíÑ ÇáÓíÇÍì”), I tried to save the file in another encoding (UTF-8) but still same result, I desperately need to read this arabic text as this is the only back up we have
Thanks
Try right-clicking the file in VS solution explorer, then choose:
This should force VS to read the file with a unicode encoding, rather than as single byte text.
Although you are saving in
UTF-8, the file may be missing theByte Order Mark (BOM)forUTF-8at the beginning of the file. ABOMforUTF-8files is optional.Update
If the file has no
BOM, try:Update
The file is not unicode encoded, it requires opening with an Arabic codepage. Try opening as follows, or with one of the other Arabic codepages: