Skip to main content
Participating Frequently
March 7, 2018
Question

I need a field to be populated with the current time of the tablet it is being filed on

  • March 7, 2018
  • 1 reply
  • 586 views

i need a "start time" field to be field with the current time once its clicked on

time must come from  the  tablet (android if relevant) it is being filled on

This topic has been closed for replies.

1 reply

try67
Community Expert
Community Expert
March 7, 2018

The code to do it is:

this.getField("Field name").value = util.printd("mm/dd/yyyy HH:MM", new Date());

However, there's no guarantee it will work on a mobile device.

Participating Frequently
March 7, 2018

How do i decide of when the time is recorded?  it need to happen when the user clicks the box

try67
Community Expert
Community Expert
March 7, 2018

Then attach the code to the button's Mouse Up event.