How to autofill a date field in Adobe Acrobat Pro with today's Date ?

    Hello everyone!

    I am trying to create a form using Adobe Acrobat DC. In my form, there is a date field that I would like to be auto-filled with today's date as soon as the file is opened.

    I know this is possible in Microsoft Word. Could you please let me know if it is possible in Adobe Acrobat and, if so, how?

    thnx, George

    • Best Answer
    • Admin

    Dear George,

    Welcome to our forum,

    Yes, this is also possible in Adobe Acrobat DC (pro). Please follow the below steps to be able to auto-fill a date field in a PDF file:

    1- From the top menu click on "Tools"

    2- Then select "JavaScript" from the available tools (click on add then open).

    3- Then from the top menu click on "All JavaScripts"


    4- Then remove everything what is inside and paste the following line:

    JavaScript
    this.getField("YOUR-FIELD-NAME").value = util.printd("dd/mm/yyyy", new Date());

    Please note that there are two parts, which you should change in the above line:

    Change YOUR-FIELD-NAME to the name of your field. And also dd/mm/yyyy to the exact date format which you have set for your date field.

    Then save and close your file. Then next time which you open your file, your date field will be automatically field with the date of today.

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!