Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
BedrockMission!

Learn More

View all

Sign in to view all badges

Javascript Not Executing on Form Server for a Dynamic XDP File

Avatar

17-12-2008

I created several xdp designs using Lifecycle 7.1. Included in these xdp's are some subforms and elements with some Javascript embedded in the docReady event. Everything runs like a gem in the Lifecycle preview, but when the xdp is deployed to the server, none of the scripts run. I confirmed that by replacing my code with simple messageBox alerts, and these did not even show when run on the server.



Here is an example of some of the scripts that I am running:

/*****Begin:******/

//If Name is not present

if(loanRequest.RepaymentsPage.Header.LeftGroup.participantName.dataNode.isNull)

{

loanRequest.RepaymentsPage.Header.LeftGroup.participantName.presence = "hidden";

}



//If Loan Number is not present

if(loanRequest.RepaymentsPage.Header.LeftGroup.loanNumber.formattedValue == "-1")

{

loanRequest.RepaymentsPage.Header.LeftGroup.loanNumber.presence = "hidden";

}

/*****End:********/



I did quite a bit of reading in this forum and made sure I selected the File>Form Properties>Defaults>Server>"Override Default Rendering" checkbox as well as setting the "PDF Render Format" to "Acrobat 7.0.5 Dynamic PDF". I have still had no success in getting the scripts to run on our Adobe Form Server. I double checked and I and the people doing the testing are both using Acrobat Reader 8.0.



Is this a problem with my settings for the XDP's that I have created, or is it a problem with the configurations of our server? Please let me know what you think.



Thanks!



Ben

Replies

Avatar

Avatar
Give Back
Level 1
AmiAdobe
Level 1

Like

1 like

Total Posts

8 posts

Correct Reply

0 solutions
Top badges earned
Give Back
Boost 1
View profile

Avatar
Give Back
Level 1
AmiAdobe
Level 1

Like

1 like

Total Posts

8 posts

Correct Reply

0 solutions
Top badges earned
Give Back
Boost 1
View profile
AmiAdobe
Level 1

09-12-2020

This message is very old. I'm still facing the same problem. Any reply?

Avatar

Avatar
Establish
Employee
Kosta_Prokopiu1
Employee

Likes

149 likes

Total Posts

340 posts

Correct Reply

96 solutions
Top badges earned
Establish
Give Back 5
Give Back 3
Give Back 25
Give Back 10
View profile

Avatar
Establish
Employee
Kosta_Prokopiu1
Employee

Likes

149 likes

Total Posts

340 posts

Correct Reply

96 solutions
Top badges earned
Establish
Give Back 5
Give Back 3
Give Back 25
Give Back 10
View profile
Kosta_Prokopiu1
Employee

10-12-2020

This age old message never contained the information needed to help this guy. There are many reasons why it did not work on the server, starting with where the script is allowed to run (Client, Server, Client+Server) or which events, as not all of them can execute on the server. Click, Enter, Exit, Change etc only work with interactive forms inside Adobe Reader/Acrobat. Also, how did he save the form/render the form. If you create a static print PDF then event execution is different to what it is interactively. Finally, xfa.host.messageBox DOES NOT WORK ON THE SERVER 🙂 That is not a valid proof that the script does not work.

 

No problem for two people is exactly the same - so you should provide more details about your form here to get help.