none
Date to text conversion on custom list

    Question

  • Hello,

    I created a simple list to fill with vacation requests. I have 3 simple columns: one is to write the type of vacation and 2 that I use for start and end date.

    Now, I'm trying to create a workflow with Microsoft Flow and when I fill a new item in the list the flow starts and send an email to the manager: the flow service, at this time, has only US locale formatting for date and time so my mail is not, say, well formed (I am in Italy).

    A little workaround that I can use is to pass to flow service the date and hour converted as string, so I thought to create 2 hidden columns that I can fill with date and hour converted to string.

    I'm quite new to Sharepoint so I ask for help: I have seen that I can create a calculated column and found a formula to do this conversion, but when I apply the formula I obtain the an error.

    Say that the field is DateFrom, so I found the formula =(TEXT[DateFrom], "dd mm yyyy") but I have an error when I try to create the calculated column with this: could someone help me to understand why I have an error?

    Hope someone can help me.

    --

    Regards


    Marco Mangiante

    Friday, October 7, 2016 6:44 PM

Answers

  • Hello,

    I resolved: to have a working formula, between the field and the formatting string you have to enter a semicolon and not a comma; so, for example, the working formula for me is:

    =TEXT([DateFrom];"dd mm yyyy")

    I think this is related to language and regional settings, so I suppose that if I change my locale settings I can use the "comma" version of the previous formula.

    However, I even found a simple workaround with the use of DAY, MONTH and YEAR functions; for example with this:

    =DAY([DateFrom])&"/"&MONTH([DateFrom])&"/"&YEAR([DateFrom])

    Hope this can help other people.

    --

    Regards,


    Marco Mangiante

    Saturday, October 8, 2016 5:15 PM

All replies


  • Marco Mangiante

    Friday, October 7, 2016 6:53 PM
  • Hello,

    I resolved: to have a working formula, between the field and the formatting string you have to enter a semicolon and not a comma; so, for example, the working formula for me is:

    =TEXT([DateFrom];"dd mm yyyy")

    I think this is related to language and regional settings, so I suppose that if I change my locale settings I can use the "comma" version of the previous formula.

    However, I even found a simple workaround with the use of DAY, MONTH and YEAR functions; for example with this:

    =DAY([DateFrom])&"/"&MONTH([DateFrom])&"/"&YEAR([DateFrom])

    Hope this can help other people.

    --

    Regards,


    Marco Mangiante

    Saturday, October 8, 2016 5:15 PM
  • Hi Marco,

    Thanks for your sharing! It will be beneficial to others in this forum who meet the same issue in the future.

    In addition, as you have solved this issue, please mark your reply as answer.

    Wendy


    Please remember to mark the replies as answers if they help and unmark them if they provide no help.
    If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com

    Monday, October 10, 2016 2:09 AM
    Moderator