The default locale of DateTime columns in the Dataview web part

More bugs in the dataview webpart – this time not being able to set the default locale for the page’s dates to being UK. When you add a datetime column to the view, if you look at the code, I can see the locale of 1033 (en-us), and the date formats available are only US format.

On my system, however, while the date formats appear to be US format in SharePoint designer, the code for a datatime column that I add to the view contains the 2057 locale (en-gb) , and the date formats display correctly in the page itself.

So it’s almost like SharePoint designer thinks it is working with US date formats, despite the settings of the Page Editor settings page, the Regional settings on the machine, and the Regional settings on the site all being set to UK date formats. I don’t know if I’m missing a setting somewhere, but if I am, I really don’t see it!

This problem can be fixed by resetting the locale by hand in the code, but really, you shouldn’t have to.

Advertisements
The default locale of DateTime columns in the Dataview web part

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s