Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

We have a number of forms using a standard DFWP to serve up some simple forms. A few of these forms have datetime fields only showing the date portion. We're experiencing some issues where user A in timezone X enters a date. Then users B in timezone Y comes and looks at the same form and sees a date either one day earlier or later. How can we make sharepoint display the same date for all users, regardless of their timezone?

So far what I've unsuccessfully tried is creating a custom field control inheriting from DateTimeField, with this markup.

<SharePoint:RenderingTemplate id="DateTimeNoTimeZoneField" runat="server">
<Template>
    <SharePoint:DateTimeControl TimeZoneID="2" UseTimeZoneAdjustment="false" id="DateTimeField" runat="server"/>
</Template>

But that is having no effect.

share|improve this question
add comment

1 Answer 1

To my knowledge there is no mechanism by default that could enabled you to do this. You could however rely on having top-level site push down same Regional Settings to sub-sites (via a event receiver monitoring changes) and in your DVWP rely on functions in the ddwrt namespace to format dates the same way for everyone (you could use LCID which is available in the $language XSLT variable to convert the date accordingly).

http://amavs.wordpress.com/2010/12/16/date-comparison-formatdatetime-function-ddwrt-namespace/

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.