Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

Adobe Summit 2023 [19th to 23rd March, Las Vegas and Virtual] | Complete AEM Session & Lab list

Automatically displaying date and time in a date/time field on form initialize


Level 5

Good day all;

I am trying to have the current date and time automatically be generated in a “date/time” field when the form is opened.

I went through the forum and found an entry from Srini “"" + Date());” . Of course this brought up a system message box with the date and time.

I then tried “DateTimeField1.rawValue = (“”+date())… This also gave me a system message box with the date and time…

Please let me know where I am going wrong


1 Reply


Level 5

Found the answer... And yes... in was in the "help" section... What can I say I was making it a lot more crazy than I needed to.

You can use a date/time field to automatically show the current date by using the Runtime Property option in the Value tab of the Object palette.

When using a current date field, the date updates to reflect the system’s current date each time a user opens the form.


In the Library palette, click the Standard category and drag a Date/Time Field object onto the form design.


In the Object palette, click the Value tab and select Calculated - Read Only from the Type list.


Select the Runtime Property option.


View the form in the Preview PDF tab.

The ultimate experience is back.

Join us in Vegas to build skills, learn from the world's top brands, and be inspired.

Register Now