I have a string: ‰€‹†… ‰‰‰ ;
I want to display it in a textbox but with it's hebrew value .
I know for a fact that it is a hebrew string but something with the encoding set the result to the string you see.
How can I convert it in my Code so I can see it in hebrew.
I tried:
string a = " ‰€‹†… ‰‰‰ " ; string b = " âìéåï " ; // this string works. Encoding latinEncoding = Encoding.GetEncoding("Windows-1252"); Encoding hebrewEncoding = Encoding.GetEncoding("Windows-1255"); byte[] latinBytes = latinEncoding.GetBytes(a); string hebrewString = hebrewEncoding.GetString(latinBytes); textBox1.Text = hebrewString; The thing is that if the string was b , it works. but all my strings are as a.
" ‰€‹†… ‰‰‰ "is latin encoding?File.ReadAllText(filePath,hebrewEncoding);, your ultraedit may open the file with right encoding, if the code I suggested doesn't work, you can try withlatinEncodingfirst, then convert tohebrewEncoding textlike as you do in your code.