Reputation: 2705
In an asp.net application, I need to get the local machine's culture. I have already changed the thread's culture to the current user's at this point so I have "written over" that.
System.Threading.Thread.CurrentThread.CurrentCulture System.Threading.Thread.CurrentThread.CurrentUICulture
Now I need to get what the machine is set to for logging purposes.How do I do that?
Thanks, Brian
Upvotes: 1
Views: 978
Reputation: 4084
The default culture is set in the machine config of your application:
See: http://msdn.microsoft.com/en-us/library/hy4kkhe0.aspx
This controls, which culture your threads have - if you dont change them. So you have to read the value of System.Threading.Thread.CurrentThread.CurrentCulture before you alter it.
If for some reasons this is not possible, you may consider
Upvotes: 1