Date format and Sharepoint list - InfoPath Dev
in

InfoPath Dev

Date format and Sharepoint list

Last post 04-20-2010 11:14 AM by Brucacuda. 4 replies.
Page 1 of 1 (5 items)
Sort Posts: Previous Next
  • 12-01-2009 06:12 AM

    Date format and Sharepoint list

     Hi

    In my Infopath form i have two date-fields in a repeating table.  Its formatted like DD-MM-YYYY. But the view in my Sharepoint list after submitting the form, shows the dates like this: YYYY-MM-DD.

    In properties for submitting, the date fields are concatenated.....

     

    Any solution?

    Thanks in advance.

     

    /Michael

  • 12-01-2009 07:51 PM In reply to

    Re: Date format and Sharepoint list

    InfoPath uses XML data types which by default uses YYYY-MM-DD as the underlying representation. You are concatenating these values in a string on submit, so you will need to change the format before at that time. You could write code to do this or you could add a text field to your form and a rule action on submit that sets the value by concatenating substrings. Use the substring-after and substring-before commands with fixed length to extract the YYYY, MM, and DD from your date string and concanate in the format you want. Then, you can promote this field to SharePoint

    Patrick Halstead
    Project Manager at Qdabra
  • 01-20-2010 11:04 AM In reply to

    Re: Date format and Sharepoint list

     I just wrote up a document over how to do this very thing when using current the date as part of the name of the document when it is submitted:

    Normal looking date (01-15-2010) in a string:

    concat(substring(now(), 6, 2), “-“, substring(now(), 9, 2), “-“, substring(now(), 1, 4))

    1. In InfoPath, go to your Data Connection in the form
    2. Use the Data Connection Wizard to go to the File Name and click the formula button then plug the formula above in red in

     

     

     
    Bruce Burns
    Sr. SharePoint Developer
  • 04-20-2010 10:04 AM In reply to

    Re: Date format and Sharepoint list

    The images seems to broken, is it possible to resend,

     Regards,

  • 04-20-2010 11:14 AM In reply to

    Re: Date format and Sharepoint list

    I don't think infopathdev is allowing anyone to post images on the forums anymore because now they have it set to be hosted elsewhere.  I suspect that's the reason they're gone from above now...

    Bruce Burns
    Sr. SharePoint Developer
Page 1 of 1 (5 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.