I am wondering the best place in my web application tiers to user regional settings to format date column output from a database results query.
I can get the regional settings from the HttpContext.Request and pass this as a string to the Business Layer and then use System.Globalisation in the Business Object Layer to create a DateTimeFormatInfo object.
ie. DateTimeFormatInfo dtfi = CultureInfo.CreateSpecificCulture(cultureString).DateTimeFormat;
The business layer fetches the data from a Data Access Layer and using a LINQ query selector the date column can be formatted with the dtfi object above.
However I am wondering if I really should be passing a string with the language-culture to the business layer and should instead load up another anonymous type with the data returned from the business layer and add the date formatting in the controller.
This would avoid the situation of a WPF app passing the culture info of the executing threa to the same call in the Business layer.