Turkish character in asp.net

坚强是说给别人听的谎言 提交于 2019-12-06 15:10:09

This (infamous) case is known as the Turkish I Problem. Jeff Atwood has written about it: What's wrong with Turkey? If you uppercase a Turkish lowercase dotless i, it becomes the uppercase English I. Then, if you lowercase that, it becomes an English lowercase dotted i. (That is, the operation is not commutative.) See this link for the solution.

As I recall the Turkish "ı" is one of the two cases where converting to upper case and then back to lower case again will not yield the original string. The other one is the German sharp "s" (i.e. ß).

What exactly is the result of the StrConv call?

Are you a native Turkish speaker and do you expect a specific result? If Yes: There might be a bug in the .NET CLR. Then please post the exact .NET version you are using.

Otherwise the result might be perfectly fine even though it looks strange for a non-Turkish user.

I'm German so for the German sharp s: There is no upper case ß. Lower case is "ß". Convert to upper case: "SS". And back to lower case: "ss"

Ali Ozger
FileReader = New StreamReader(OpenFileDialog1.FileName, Encoding.Default)

Encoding.Default solves this problem in vb.net

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!