Adobe LiveCycle preview PDF

Avatar

Avatar

brianw81860517

Avatar

brianw81860517

brianw81860517

11-05-2016

Form fields update correctly when viewing in livecycle but not when opened in adobe x pro.  Specifically two field I have.  One for the current date and one for the current time.  When I view them in the PDF viewer in Livecycle everything works fine.  But when I open the document in Adobe X Pro or Adobe Reader XI, both fields display the date and time from when it was saved last in Livecycle...how do I make it work the way it does in the PDF viewer??

Accepted Solutions (0)

Answers (7)

Answers (7)

Avatar

Avatar

radzmar

MVP

Total Posts

2.6K

Likes

386

Correct Answer

485

Avatar

radzmar

MVP

Total Posts

2.6K

Likes

386

Correct Answer

485
radzmar
MVP

17-05-2016

This wouldn't make sense, because then the field will be reset everytime you reopen the form.

Then you can also use the script:

$.rawValue=num2date(date (), "MMMM DD, YYYY")

Avatar

Avatar

brianw81860517

Avatar

brianw81860517

brianw81860517

11-05-2016

Can't I force this field to zero out with FormCalc formulas when the document is opened?  Something like this:

$.rawValue=null then

if($.isNull) then

$.rawValue=num2date(date (), "MMMM DD, YYYY")

endif

endif

Avatar

Avatar

brianw81860517

Avatar

brianw81860517

brianw81860517

11-05-2016

It still only reflects the date that it was saved in Livecycle.  It's not clearing that field.  And I have no idea why...  Also, if I can get this working with the JS Debugger, will this work for anyone who opens the form?  Or would this Debugger script need to be placed on every PC?

Avatar

Avatar

radzmar

MVP

Total Posts

2.6K

Likes

386

Correct Answer

485

Avatar

radzmar

MVP

Total Posts

2.6K

Likes

386

Correct Answer

485
radzmar
MVP

11-05-2016

The return value in the console is null, so the field has been cleared (it also should be cleared in the form as well). Now Reader-enable your form. Next time you open in you should get the current date.

Avatar

Avatar

brianw81860517

Avatar

brianw81860517

brianw81860517

11-05-2016

I did exactly as you said...and nothing seems to be happening.

This is my LC field:

934942_pastedImage_0.png

And here is the Java Debugger field.  Debugger is acting strange though.  I cannot make the window any larger than it is and when I attempt to initialize it nothing happens.  And the same script will show up in debugger windows on other documents...

934952_pastedImage_1.png

Avatar

Avatar

radzmar

MVP

Total Posts

2.6K

Likes

386

Correct Answer

485

Avatar

radzmar

MVP

Total Posts

2.6K

Likes

386

Correct Answer

485
radzmar
MVP

11-05-2016

This behavior is correct, because once saved, the fields aren't empty anymore so the script doesn't fire again.

To solve this problem see this thead: Re: Reader extension

Avatar

Avatar

brianw81860517

Avatar

brianw81860517

brianw81860517

11-05-2016

This is what I'm using with formCalc:

if(F.P1.DateTimeField1.isNull)then

F.P1.DateTimeField1.rawValue=num2Date(Date(), "MMMM DD, YYYY")

endif

Seems really simple and works without issue in the PDF viewer...