none
SharePoint date label shown wrong

    Question

  • Hello,

    I've made a custom view in which I have a date. However de date is shown ad <xsl-value-of node-walk="118" select="@Startdatum">2012-04-04T22:00:00Z in stead of 2012-04-04. How can I change this?</xsl-value-of>

    <xsl-value-of node-walk="118" select="@Startdatum">I've tried this code:</xsl-value-of>

    <xsl:value-of select="@Startdatum" />

    and this code

    <asp:label runat="server" id="ff7{$Pos}" text="{@Startdatum}" __designer:bind="{ddwrt:DataBind('u',concat('ff7',$Pos),'Text','TextChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@Startdatum')}" />

    Both do not work.

    Any ideas?

    Remco     

    <xsl-value-of node-walk="118" select="@Startdatum"></xsl-value-of>

    Friday, April 06, 2012 8:16 AM

Answers

  • Change select="@Startdatum"

    to select="msxsl:format-date(@Startdatum,'MM/dd/yyyy')"

    like the following:

    <xsl:value-of  "msxsl:format-date(@Startdatum,'MM/dd/yyyy')"/>

    Monday, April 16, 2012 10:58 AM

All replies