i need set cultureinfo windows service, written in c# 4.0. trouble in os locale - differs service's culture.
because using .net 4.0 (in .net 4.5 may change default culture all new threads), question is:
how can handle creation of new threads in windows service, , set cultureinfo them?
a windows service doesn't mean multiple-thread program. must create thread in code or service wcf service. if create thread yourself, set culture of new thread after created. if it's wcf service, please see http://msdn.microsoft.com/en-us/library/system.servicemodel.dispatcher.idispatchmessageinspector.aspx. need implement interface idispatchmessageinspector , if there new request client (a new thread might created) method afterreceiverequest called, set cultureinfo within method. if windows service not wcf service, please show more information it.
Comments
Post a Comment