Is it possible for the datepicker to exclude the time?

  • cemerey
    Asked on August 10, 2017 at 2:05 AM

    Hi Guys,

    I've got a date picker on my form with the Time Field set to OFF.

    Microsoft Flow picks up the time along with the date.

     

     

    Is it possible to exclude the time if the time field is set to off?

     

    Example below:

     

     

    Is it possible for the datepicker to exclude the time? Image 1 Screenshot 30

    Is it possible for the datepicker to exclude the time? Image 2 Screenshot 41

  • nurscukulatt
    Replied on August 10, 2017 at 3:15 AM

    1- You can use “Date Time Single” Widget. First, you can add it from "Widget" Section as it is shown below. 

     Is it possible for the datepicker to exclude the time? Image 1 Screenshot 90

     

    Then from the widget's settings modify it as below. 

    Is it possible for the datepicker to exclude the time? Image 2 Screenshot 101

    It will be seen as following :

    Is it possible for the datepicker to exclude the time? Image 3 Screenshot 112

     

    2- Also you can use one additional tool to your example. Add “Time” element from “Basic” section as it is shown below. 

    Is it possible for the datepicker to exclude the time? Image 4 Screenshot 123 

    Then modify element's properties as below.

    Is it possible for the datepicker to exclude the time? Image 5 Screenshot 134

    It will be seen as following :

    Is it possible for the datepicker to exclude the time? Image 6 Screenshot 145

     

    3 - Another solution is to modif “Date Picker” element which is from “Basic” section.  Edit it's properties as below. 

    Is it possible for the datepicker to exclude the time? Image 7 Screenshot 156

    It will be seen as following : Is it possible for the datepicker to exclude the time? Image 8 Screenshot 167

    Hope this will work. Please contact us if you need anything else. 

     

     

     

  • Kiran Support Team Lead
    Replied on August 10, 2017 at 4:13 AM

    @cemerey,

    I understand that the date field is also sending the time to Microsoft Flow and you want to send only the date. Could you let us know to which application you are sending the JotForm submission to so that we can test it further? 

    We will wait for your response. Thank you! 

  • cemerey
    Replied on August 10, 2017 at 4:46 AM

    @Kiran 

    Yes I'm trying to use the DatePicker to send only the date to MS Flow using the Jotform connector. See form and response below:

    Is it possible for the datepicker to exclude the time? Image 1 Screenshot 30

     

    Is it possible for the datepicker to exclude the time? Image 2 Screenshot 41

  • Support_Management Jotform Support
    Replied on August 10, 2017 at 5:55 AM

    Hey @cemerey - I'm afraid MS Flow uses the UTC format (including the time) by default and this is something beyond our control.

    Luckily, after digging around, I found an option in MS Flow where you can use @formatdatetime to change the format of the date field regardless of the source of the trigger (whether it's from JotForm or not).

    I found the following Poweruser threads that are related to your problem:

    https://powerusers.microsoft.com/t5/Building-Flows/Sharepoint-Datetime/m-p/42279#M3843

    https://powerusers.microsoft.com/t5/Connecting-To-Data/formatDateTime/td-p/24013

    And here's a related tutorial I found online:

    http://www.gilleran.net/sharepointireland/index.php/change-date-format-in-microsoft-flow-emails/ 

  • cemerey
    Replied on August 10, 2017 at 7:01 PM

    I wasn't aware that was an option on MS flow. But I was able to format the date following the links you provided. 

    Thank you

     

    Is it possible for the datepicker to exclude the time? Image 1 Screenshot 30

    This is what I have in the expression

    formatdatetime(triggerBody()?['04 - Date Picker'],'dd-MM-yyyy')

     

    Is it possible for the datepicker to exclude the time? Image 2 Screenshot 41

     

    Thanks again

     

  • Support_Management Jotform Support
    Replied on August 10, 2017 at 7:28 PM

    Awesome stuff! I'm glad that's exactly what you need 😊