obtaining thread info

  • Thread starter Thread starter rodchar
  • Start date Start date
R

rodchar

hey all,
is there a way to get to Thread.CurrentThread.CurrentUICulture in my
webservice code?

thanks,
rodchar
 
hey all,
is there a way to get to Thread.CurrentThread.CurrentUICulture in my
webservice code?

Well yes, since every thread has a culture and a UI culture... and you
do it in precisely the way you've described. The question is, why?
CurrentUICulture is supposed to be used for purposes such as
formatting numbers & dates according to user preferences. A
webservice, by definition, has no UI, and it should certainly never
format anything in its XML response using UICulture!
 
thanks for the insight,
rod.

Pavel Minaev said:
Well yes, since every thread has a culture and a UI culture... and you
do it in precisely the way you've described. The question is, why?
CurrentUICulture is supposed to be used for purposes such as
formatting numbers & dates according to user preferences. A
webservice, by definition, has no UI, and it should certainly never
format anything in its XML response using UICulture!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top