Saturday, November 28, 2009

How to get a message of an exception in English.

Recently I faced with problem of getting a message of an exception in Russian language while running .NET 3.5 application. I don’t know why Microsoft decided showing exceptions’ messages using local language. Usually exception shouldn’t be shown to a user at any circumstances, and developers should handle them and show appropriate message to the user if needed. Personally I don’t know developers who can’t understand English, at least at basic level. So I think that exceptions should always be shown in English, rather than on other languages, because any developer can perform relevant google-search using English messages, and I’m not sure if he/she will get any results on his/her native language. For instance I haven’t got any results for Russian description of the exception, but I have got a lot for English original.
The only way to get English translation for an exception, is to change current culture to English (to “en-US” for instance) just before a place where the exception occurs or change the culture of whole application via its configuration file.


Ilya Troitskiy said...

як гарно вы говорите... У нас в кооперации теж начали учить англицку: воркер - гуд, капитализм - бэд (с) ДеЖаВю

plotnick said...

Normal application shouldn't show any exceptions at all... ;)

Id Muborak!

Bashir Magomedov said...

2Ilya. Ну дык, надо привыкать.
2plotnick. I think that "normal" is not the right word for such kind of applications. Perfect, excellent, fantastic are much more appropriate :)

Wa iyaka, bro. May Allah accept from you and from us. Amin.