Embedding a "Current Date" field in a pdf document

To assure people work to the latest authorized version of a procedure, we let them access a protected pdf version on our Intranet. They can print a copy for use, but the copy is valid ONLY for the date printed, which is shown in the footer of each page. The "current date" field is updated when the document is opened by way of a Java script that reads:
var f = this.getField("Today");
f.value = util.printd("mm/dd/yyyy", new Date());
(Obviously, "Today" is the field's name.)
If a person were to open the same document three days later, that later date would be embedded.
All this worked well when we were using Acrobat 5 and Reader 5. Now, to keep up with the times, we've upgraded to Acrobat 8 and Reader 8 on many PCs. However, the "current date" field still works for those still using Reader 5 but doesn't work for those using Reader 8.
What I'm wondering is whether the scripting has changed for Acrobat 8. I can't find anything in the Acrobat support documents for Java scripting, but I may not know what I'm looking at.
Thanks,
Jerry Holt
[email protected]

The problem has been solved!!!
The form field, the accompanying script, and most documents' security were set up in Adobe 4.0. However, in Adobe Reader 7 or higher, "no changes" means "no changes," so the form field script was blocked.
By setting Compatibility to "Acrobat 7.0 or greater," I could choose the "Change Allowed" option: Filling in form fields and signing existing signature fields.
Then, all I needed to do was to confirm that the JavaScript "Today" was still applied, and the current date was immediately filled in.
Thanks for the questions and suggestions.

Similar Messages

  • Adding a year to the current date field

    Hello,
    Can any one please help on how to add a year to the current date field.
    e.g 7/19/2011 plus a year = 7/19/2012
    Thanks,
    Han Dao

    If you had a field DateTimeField1 and wanted to display the following year in DateTimeField2, you could do the following in JavaScript;
    var d1 = util.scand("yyyy-mm-dd", DateTimeField1.rawValue);
    if (d1 !== null)
    d1.setFullYear(d1.getFullYear()+1);
    DateTimeField2.rawValue = util.printd("yyyy-mm-dd", d1);
    Good luck
    Bruce

  • Current Date Field question

    Hello
    I'm a novice user of LiveCycle and I'm trying to see if there's a solution for this issue we've come across.
    We've used LiveCycle to redesign human resource/payroll forms in our organization. One of the items we use is the current date field, which automatically populates to today's date once opened. When users complete forms, we encourage them to save an electronic copy of the form to their own drive in case they need to retrieve it at a later date. The problem here is that the current date field will not stay static once filled out and saved.
    For example, if a dept completes a form on 12/1/10, saves it, but then needs to retrieve it later for some reason, we need the current date field to stay as the date the form was originally filled out (12/1/10). If they retrieve the form later on say 2/15/10, that particular date field will read the new date. Is this possible?
    Thanks for any help!

    Test if the field is null before assigning the current date.
    // form1.page1.currentDate::ready:layout - (FormCalc, client)
    if (this.isNull) then
      $.rawValue = Concat(Num2Date(Date(), "MM/DD/YYYY"))
    endif
    Steve

  • How to read data/fields of the pdf form

    Hi,
    i want to orchestrate a process where input is interactive forma and output is xml data.
    i mean i want to read data/fields of the pdf form.
    Which activity do i use on workbench.
    Regards
    Sunil

    Dieter,
    I am talking about 3rd senario, where we create one process on workbench, and pass filled pdf as input and then output of process is xml file.
    What is the process name here (Like renderPDF process) which extract data from pdf.
    regards
    Sunil

  • Can a user override the Current Date field?

    I have a simple form with a Current Date field.  Today's date is automatically populated in this field, but I would like to give users the option to enter a different date in the field.  There is a value called "Calculated - User Can Override" but this doesn't appear to work.

    When I first set up this field I used code I found on this forum that went in the 'layout:ready' area.  I've now removed it and used the code I found in your file in 'calculate'. The date field is now functioning properly.
    Thank you.

  • Changeable Current Date field

    I need the "Current Date" field enabled to be changed by the user. Any help will be appreciated.
    I thought the "Calculated - User can Override" would work but no such luck! (I am using the Custom - Current Date field)
    Thanks

    Hi,
    The custom current date has the script in the layout:ready event. This fires everytime the user exits an object that has been changed.
    So what is happening is that the user can access the date field and change the value, however when they exit the field, the layout:ready event fires and the user-entered data is overwritten by the current date.
    You could move the script from the layout:ready event to the docReady event. This is a good event because it only fires once, when the form is opened/rendered.
    You will probably need to wrap the script in an if statement, so that when the form is reopened, it does not overwrite the date. The following FormCalc should work:
    // Current Date in short-style date format.
    if (HasValue($) eq "false") then
         $.rawValue = num2date(date(), "DD.MM.YYYY")
    endif
    There is an example here: https://acrobat.com/#d=QR1y1RYatwSaQAWa4-jLlA
    You can see events and how they fire here: http://assure.ly/gW3RNr
    Hope that helps,
    Niall

  • Duplicating form fields from one PDF document to another

    Hi,
    Does anyone know of a way to select and duplicate all acrobat form fields from one PDF document into a new PDF document. I know I can do so one field at a time but would like to know if there is a way to do so in a wholesale fashion.
    Our PDF documents are created in-house each year and are nearly the same as the previous year's document containing 99% of the same form fields in the same locations. These forms contain a lot of form fields, anywhere from 50 to 100 fields.
    Rather than start from scratch each year defining the same fields that were present in the previous year's document, I am looking for a way to copy the form fields from an existing PDF document (last year's PDF in our case) and copy the form fields into a new PDF document (that does not yet have any form fields defined) and hopefully maintain all the field attributes and positions from the previous years document.
    Thanks for any suggestions,
    Steve

    The PDF template we need to copy the form fields "to" doesn't start out having any form fields. It is the fields that we need copied from a previous year's PDF template.
    Here's an except from my original post: "I am looking for a way to copy the form fields from an existing PDF document (last year's PDF in our case) and copy the form fields into a new PDF document (that does not yet have any form fields defined)"
    The "new" PDF template is a complete "paper" form with updated legal text and calendar year referrences but NO form fields. In our IS group, we then take these forms, add form fields to them and are then able to populate them with database-resident user data. We serve them up to the user in their browser pre-populated with their application data.
    So again, our need is to find a way to copy form fields from "last year's" PDF template and copy just the form fields to an fresh "new year's" PDF template that contains no form fields to begin with. What we begin with is just a PDF representation of a paper student loan application.
    Thanks for the suggestion!

  • How can I update data fields in a merged document ?

    Hi,
    I'm looking for a way to update the values of data fields in a merged document with a script just as you can do with the user interface.
    I don't find any method like "updateDataFields ()" in the DataMerge object.
    Si I try to invoke the menu action "Update Data Fields", but it fails. The script error message is: "Error 53762, the script is not active." On the contrary, the action works if I use the interface.
    Can anyone help me?
    Thanks in advance,
    FredIsnard
    PS : I work with CS5.5 and JavaScript.

    Hi!
    You might be looking for this one:
    DataMerge.mergeRecords (outputOversetReportFile: File )
    Merges records and produces an optional overset report.
    outputOversetReportFile: Data Type: File
    The path to the file in which to store the overset report. (Optional)
    Best regards,
    Andreas

  • Does anyone know how I can create a text field in a pdf document that will multiply a total in another box?

    does anyone know how I can create a text field in a pdf document that will multiply a total in another box? I’m making an interactive pdf for an order form (attached), and I need to find a way for the “total quantity” number to multiply by 9 and total in the “Amount Due” box.

    Hey Gary,
    Have a look at this post: Re: horizontal scrolling similar to excel
    Andy's reply will show you how to make a table scroll horizontally, but it will be tough to accomplish it in some sort of easily replicable way. I am working on a JQuery extension that will help accomplish this, but I have had my time invested in another project at the moment.
    Good Luck,
    Tyson

  • Problem with current date field...

    I want to display the current date and time, but when I change the data format in the binding tab to "Date and Time" and assign a pattern that includes date and time, all I get is the current date, NOT the time. TIA!

    I have tried applying these scripts in the initialize event to all manner of objects, text field objects, date/time objects, numeric objects, current date objects, and it shows nothing. If I could just edit the date/time format of the current date object when it is set to "Runtime Property-Current Date/Time" I MIGHT be able to use it. I really appreciate your help thus far. Would it be possible for you to share a pdf file that you've made where this works so I might disect it? No matter what pattern I specify in the "Field" palette, it shows it's own formatting.
    UPDATE: I did go back after trying it a few times to change the value after Page1 to match the name of my field.
    UPDATE 2: Here is a link to what I've done. Take a look and let me know what I'm doing wrong, or change it and share it back. Thanks so much for your help!!!
    https://www.dropbox.com/s/1so2hcao372k37z/Script%20Examples.pdf
    Vipin Bhargava wrote:
    I have found 3 more variants. You can write below code on initialize event. It will automatically display the current data & time during the preview
    1.   xfa.form.form1.Page1.TextField1.rawValue
    = util.printd("dd.mm.yyyy HH:MM", new Date()); 
    2.  xfa.form.form1.Page1.TextField2.rawValue = util.printd("dddd d. mmmm yyyy HH:MM ", new Date());
    3.  xfa.form.form1.Page1.TextField3.rawValue = util.printd("date{EEEE, D. MMMM YYYY} time(de){HH:MM:SS Z}", new Date(), true);
    Hope this helps,
    Vipin

  • How to seperate current page fields in a pdf form using javascript

    Hi,
    Is that possible to seperate current page fields(textbox, Chesckbox) in a pdf form using javascript.
    I have coding to get all the fields in a pdf form. But i want to take CURRENT PAGE alone.
    Please help me out.
    Thanks and regards,
    Christy

    Hi try67,
    Thanks for your support.
    I got the result.
    Thanks and Regards,
    Christy

  • Select RTF Data and display in PDF Document

    Hi all,
    I have a simple table:
    CONTENT_ID - NUMBER
    CONTENT - VARCHAR2(4000)
    On top of this table I have a form that allows the user to enter / update data. The 'CONTENT' field is a Rich Text Editor (ApEx 4.0 - CKEditor 3). This allows the user to enter and format their text as they require.
    I need to be able to select this data and display it in a PDF Document (via BI Publisher).
    I therefore have a simple query
    select content from content_table where content_id = 1;and a simple template that processes the resulting xml:
    <?xml version="1.0" encoding="UTF-8"?>
    <ROWSET>
       <ROW>
          <CONTENT>& lt;h2& gt;
         This is a heading& lt;/h2& gt;
    & lt;p& gt;
         This is the text& lt;/p& gt;
    </CONTENT>
       </ROW>
    </ROWSET>(There is not really a space between the & and 'lt' etc but I had to add this to get it to display correctly here).
    Where I run this past my template I get a PDF with:
    <h2>
    This is a heading</h2>
    <p>
    This is the text</p>I get the same if I generate HTML.
    but what I want to see is the text formatted as the user has entered in the RTF editor.
    Can this be done?
    Many thanks,
    Martin

    I think your mixing 2 technologies.
    At 1 side you have xml in combination with xsl (style sheets used in BI Publisher and FOP) to generate your pdf. And at the other side you have HTML...
    XML and HTML are 2 entirely different technologies which you can not mix this simple. I investigated the same problem as you had, and in the end I ended up using jasperreports instead of FOP.
    Maybe BI Publisher has some html regions which you could insert into your word document but I doubt it cause more people have asked the same question on this board...
    So my advice: use jasperreports (also it is free for commercial usage)
    Success
    Br,
    Nico

  • Dynamically bind website text field values to PDF document

    Hi there,
    I am in search of a step by step tutorial on how to generate a pdf document based on values from website text fields.
    I have a form produced in Live Cycle Designer ES3 and a website in which we insert test results for our company to a MySql database.
    My thoughts was that when we have inserted values on the website we could have a link to the pdf document and the same values would
    somehow magically appear on the pdf. Have read somewhere that this can be done with XML and the use of different 3rd party programs.
    Is this possible?
    What approach would be the easiest? Perhaps someone knows about a tutorial on the matter?
    Data is stored from PHP website to MySql database. Website produced in Dreamweaver CS5
    Thanks in advance for any tips/help!
    Regards,
    Christian

    It's possible with an XFA form as well as an AcroForm, but to do the work on a server additional software is needed as you mentioned. Adobe's offering is in their LiveCycle lineup and possibly . Others from third-parties include FDFMerge, PDFlib, iText, Debenu Quick PDF Library, and others. The idea is you merge the data with the PDF on the server and serve it up or save it on the server and provide a link on the HTML page that's returned. Documentation for these libraries will include samples, but you'll also have to learn how to do this securely if that's important for the system you're putting together.

  • How to extract data from  table in PDF document

    Can somebody let me know that how to read tables from a PDF document as I need to process this data further and I want it to be saved as a database.

    Google around; you might find a couple of sourceforge project.
    Rich.

  • Javascript Code to List all Signature Fields in a PDF Document

    Hi everybody,
    I am doing a VB.NET application that apply a digital signature in a PDF document.
    My VB.NET application invoke a javascript file that signs de document. It's working very well, but I need to pass the field name to place the signature, and this is not good!
    I would like to list all the signature fields existing in my PDF file, is it possible do this with Javascript? I couldn't find in the Acrobat 8 SDK documentation.
    I have installed Acrobat 8 Professional in my machine.
    Thank you in advance!

    Nobody knows?
    Help me please!
    I am reading something about a method called "event.target.name" that probably do what I need, but I couldn't use it. Am I in the right way? Any ideas?
    Thanks!

Maybe you are looking for

  • How to change color default in Mail

    I have Apple Care and called and spoke at length to tech support. I know how to set the font default but cannot figure out how to change the color default. Tech support didn't know either. I've read "The Missing Manual", gone to Mail, Preferences, Co

  • JTable ListSelectionListner Problem

    Hi All! ListSelectionEvent gets fired when there is selection change b/w different rows/cols(I can capture this event and do something) BUT not when row/column is same on two consecutive clicks. I have check boxes in first column(column class is bool

  • Default active maintenance plan in oracle 11g ?

    Hi all, I have a question about database resource manager. As i know Oracle11g automatically use the Default_maintenance_plan in the Scheduler window MAINTENANCE_WINDOW_GROUP. And the default CPU resource allocation for SYS account (SYS_GROUP) is 75%

  • Create dvd files

    Hello. I would like to know if there is any way to make/manage/create VIDEO_TS files. Or any idea what I should try to look for to find out?

  • HELP with kernel panics1

    I am getting about 4-5 kernel panics on my late 08 macbook pro! I just got it off ebay this week and i have no idea how to fix it or why its happening! I did the instructions on apple.ca for kernel panics but it still does it! And i dont know any mac