Expand my Community achievements bar.

reset button

Avatar

Community user
trying to use the rest button to only reset a image field or reset only one page of the form. can this be done???



Thank!!
8 Replies

Avatar

Community user
The reset is programmed to do the whole form. You would have to build your own reset by getting a list of objects on the page and resetting each field object individually.

Avatar

Level 2
Hi Paul, Mark,



May i know how i can hide an image to a reset button?

i've tried the following to the existing script on the rest button but it doesn't work:



xfa.host.resetData();



image1.presence = "hidden";



the reset data button doesn't work anymore.



Can you help? Thanks!

Avatar

Community user
I am not sure that I follow. Buttons do not have images associated with them. You can have objects overlaying each other so it looks like there is an image on your button but they are still 2 distinct objects.



If you have Acrobat hit Ctrl-J to bring up the java console and see if there are any errors reported.



Lastly, make sure your form is dynamic.

Avatar

Level 2
Hi Paul, sorry, maybe i wasn't clear enough....

I have a reset button on my form, this will clear all form data when clicked.



I have an image which, when the user hit on reset button, it still remains visible. So i need a script on the click event of the reset button hide it or to make it invisible.



Not that there was an image on the reset button.

Avatar

Level 2
Hi Paul, I've used the above script onto the reset butoon, but it doesn't work and to no avail.... may i know, if there is a Yes/No radio button, what value does it return? is it "0" or "Off"?



can i script:



if (radiobutton.rawvalue = "0" && radiobutton.rawvalue = "Off")

{

Image.presence = "hidden";

}



i tried plotting the scripts onto different objects to see if it works.

Avatar

Level 2
Hi Paul, Thanks.... I made it!