Expand my Community achievements bar.

Adobe Summit 2025: AEM Session Recordings Are Live! Missed a session or want to revisit your favorites? Watch the latest recordings now.

Mark Solution

This conversation has been locked due to inactivity. Please create a new post.

SOLVED

Advice : JavaScript question

Avatar

Level 1

Beginner advice :

1. script by default today's date how to express

2. default input convert lowercase to uppercase

thanks

1 Accepted Solution

Avatar

Correct answer by
Level 10

Hi,

to populate todays date use FormCalc in the docReady event.

if ($.isNull) then

     $ = Num2Date(Date(), "DD/MM/YYYY")

else

     $.rawValue

endif

To change lowercase to uppercase use JavaScript in the change event of your field.

xfa.event.change = xfa.event.change.toUpperCase();

View solution in original post

2 Replies

Avatar

Correct answer by
Level 10

Hi,

to populate todays date use FormCalc in the docReady event.

if ($.isNull) then

     $ = Num2Date(Date(), "DD/MM/YYYY")

else

     $.rawValue

endif

To change lowercase to uppercase use JavaScript in the change event of your field.

xfa.event.change = xfa.event.change.toUpperCase();

Avatar

Level 1

thanks very much