I´m struggling to find a solution to this.
I´ve created a group of 4 Radio Button (say Group1). ONly one Radio Button contains the the right answer.
I need a dialog box to pop up everytime one Radio Button is selected.
I need the checking of the Radio Button to be cleared, in case the answer is wrong.
I need the Radio Buton to remain checked, in case the answer is correct.
Thank you very much for your help/direction you can give me on this.
As Mouse UP event of Radio Button use this to get dialog box ( I assume you want an alert that answer is wrong/correct?)
app.alert("This choice is wrong/correct.", 3);
Edit message in alert as you see fit.
As Mouse Exit event of same Radio Button use this to clear Button:
event.target.value = "Off";
Don't use it in button with correct answer.
Repeat for other buttons.
Thanks a lot for your answer. You understood exactly what I wanted.
I did as you said and everything worked fine, EXCEPT for the Mouse Down event.
I inserted the "event.target.value = "off"" on it, but nothing happens. The button remains unchecked.
I also tried to invert and wrote "event.target.value = "On"" only on the button that contained
the right answer, leaving all the other blank, but again, to no avail.
Do you have any idea what might be causing this problem?
Would appreciate to receive your comments.
It's "Mouse Exit" not "Mouse Down".
Oh sorry. I just inserted the code correctly.
I inserted the same code on Mouse Exit but still, nothing happens.
unchecked, no matter what.
Because I need all the Radio button to be cleared as soon as the user opens the PDF, I
inserted a code clearing all of them. This code runs on page loading.
I don´t know if this is interfering somehow.
Thanks a lot in advance for any help.
What code did you set as Document level?
Can you share your file here?
this.getField("Group1").value = "Off"
If you can, upload your file to google drive or similar site and post link here so I can take a look into your file or you can send it to me privately if you don't want to post it here at firstname.lastname@example.org