Expand my Community achievements bar.

Learn about Edge Delivery Services in upcoming GEM session

Script behind button not working on FormGuide

Avatar

Level 3
Hi,



I have created a simple xdp that has a button and a checkbox. Behind the buttons click event I have the following:



xfa.form.memberForm.checkBoxName = "1";



When I do a preview pdf and click the button the check box gets set as I want. But I have created a form guide and added by button and check box to the form guide and when i do a Preview of the Form Guide and click the button nothing happens!



I'm pretty new to all this so hopefully someone can point me in the right direction.



Thanks,

James
5 Replies

Avatar

Former Community Member
You need to add the rawValue property to the expression. So it should look like this:



xfa.form.memberForm.checkBoxName.rawValue = "1";

Avatar

Level 3
Hi Paul,



Thanks for your reply.



I tried your suggestion but it still doesn't work in the form guide unfortunatly. It does work when I do a previef pdf in the Designer view though.



James

Avatar

Former Community Member
Can you post your XDP to livecycle8@gmail.com and I will have a look.

Avatar

Level 3
Paul,



Sent that onto that address there now, thanks.



James

Avatar

Level 3
With the help of Paul (thanks again) we managed to get this issue resolved.



The script behind the button was marked as FormCalc. FormCalc is not supported in Form Guides so by changing the dropdown to javascript and using the correct javascript code I was able to set the check box on the Form Guide.