You are viewing limited content. For full access, please sign in.

Question

Question

Short Date format in template

asked on June 8, 2016

Dear All,

i need to have my date in this format yyyy-MM-dd hh:mm:ss

however, when selecting custom format as below

when selecting the date in the preview, i'm getting this result below

i want the date also the hh:mm:ss, however, it will give me only 12:00:00 AM for all records

 

can anyone help me out

0 0

Answer

SELECTED ANSWER
replied on June 9, 2016

Hi Iqbal,

What's the goal of this field? Is it supposed to always be the current date/time? If so, you could either press the spacebar without having to use the calendar in the first place, or set up the current date/time as a default field value - in which case the users wouldn't have to do anything at all and it would just automatically populate. You could even then make it read-only so the users wouldn't even be able to change it and it would force it to be the current date/time. 

If it's not supposed to be the current date/time, what would you expect the time to be, since the calendar has no concept of time? 

0 0

Replies

replied on June 8, 2016

When you click away from the field, does it reformat? I didn't have any problems getting my field to show the format i want (I used yyyy-MM-dd H:mm:ss for 24 hour clock):

When you select a date from the calendar picker, it will automatically assign 12AM as no time can be specified from the calendar. Did you know you can populate the current datetime in the field by highlighting the field and hitting the space bar?

0 0
replied on June 8, 2016

Hello Cathy,

When i click away from the field it does not reformat.

for the second option you mentioned, when i highlight the field and hit space bar, it does pick up the time 

My users are complaining why they should do this step when the normal behavior should be select the date from the picker.

Is there any additional settings i need to configure

I did try with a new template and i'm still getting the same issue

0 0
replied on June 9, 2016

As the calendar button only allows you to select a date, it will populate the date and time will default to midnight, but it should still be reformatted with no problems:

Another option to select the current date and time is to use tokens. If you click on the arrow button on the right:

 

 

 

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.