tags:

views:

121

answers:

1

I'm building a report form in Acrobat and have a date field that I want to update by pressing form button on the page. (What I was thinking was a non-printing button.)

What Javascript would I need to place in the button to make it insert the current date in the date form field.

+1  A: 

One option: on the Actions tab of the button enter JS-

var fld = this.getField("datefield");

fld.value = util.printd("yyyy/mm/dd",new Date());

Hope this helps,

Dimitri

www.pdfscripting.com

Dimitri