required Radio Button

13 views
Skip to first unread message

Andy

unread,
Aug 20, 2009, 4:42:45 PM8/20/09
to CenoPDF Support Group
How do I make a Radio Button respond to the presence/absence of
entered text in a Text Box?

The Text Box is not a mandatory entry, but if a value is typed into
the box then one of the options in the Radio Button must be selected.

I've tried using the "required" option in Properties, but this hasn't
seemed to work- data from this document do not get "submitted", just
saved and exported to a spreadsheet, so perhaps this is why?

CenoPDF Support

unread,
Aug 20, 2009, 5:23:38 PM8/20/09
to cenos...@googlegroups.com
Hello Andi,
 
Let me make sure I understand your question. You want a text box and a group of radio buttons on the PDF file. Depending on the content of the text box, one of the radio button in that group will be selected. If this is what you want to do, you will need a javascript. Please confirm and I will create a Javascript example for you.
 
CenoPDF support

Andy

unread,
Aug 31, 2009, 6:18:28 PM8/31/09
to CenoPDF Support Group
Sorry for the delay here. To clarify:

This particular file is a survey. There is one question in radio
format that must be answered by the respondent IF the previous
question is answered elicits a certain response. If the previous
question does not elicit that response, the second question is not
applicable. I need to figure out a way to make that second question
mandatory when (and only when) it is appropriate.

For example: Question 1 would ask respondents to enter numerical
values into text boxes identifying the number of walls painted White,
number of walls painted Yellow, or number of walls Not Painted.
Respondents can enter values into any text box that applies. Question
2 would then ask the respondent to identify the predominant type of
paint used on painted walls, in radio format (i.e. Latex, Enamel,
Oil). Question 2 MUST be answered if the respondents have identified
any number of White or Yellow walls greater than zero.

Thanks for your help. I'll be quicker on the next response!

Andy

CenoPDF Support

unread,
Aug 31, 2009, 6:33:17 PM8/31/09
to cenos...@googlegroups.com
Hi Andy,
 
In your example, if the question 2 is not answered, what kind of behavior do you expect? This is related to how you are going to submit/print the form.
 
One way in my mind is that if you want to submit the form, in your submit button, you can do a check to see if all questions are answered correctly. If not, display some kind of error message.
 
Thanks,
Yang

Andy

unread,
Sep 1, 2009, 10:50:37 AM9/1/09
to CenoPDF Support Group
Yang-

If the answer to question 1 requires an answer in question 2, I'd like
to display a warning message. I would also like to make it so that
the respondent cannot continue on to the next question without
answering question 2 if it is required. I do not know how to write
the Javascript for this scenario.

This survey doesn't really utilize a "submit" function- responses are
tabulated when the form is saved, and form data is subsequently
exported into a spreadsheet.

Thanks-

Andy

CenoPDF Support

unread,
Sep 1, 2009, 11:53:53 AM9/1/09
to cenos...@googlegroups.com
Andy,

The scenario you described is quite complicated. A potential solution could
be like this:
When user open the form, the question 1 and 2 are enabled while all other
questions are disabled.

After the user finishes question 1 and 2, some javascript could be triggered
so that question 1 and 2 will be disabled and question 3 and 4 will be
enabled and so on.

This scenario also implies that user won't be able to come back to question
1 and 2 after 3 is changed.
Also what if the user want to save the form without finishing the last
question?

We can make a demo for you if you want to go this way. But I have to ask you
to purchase the Advanced Support as this will take us quite long time to
work on:
http://www.lystech.com/support.aspx

By the way, I hope are aware that Adobe Reader does not allow your user to
save the finished form unless you have Acrobat 8 or higher. See our FAQ 1:
http://www.lystech.com/faq.aspx#q1

Thanks,

CenoPDF Support
http://www.lystech.com/
No virus found in this incoming message.
Checked by AVG - www.avg.com
Version: 8.5.409 / Virus Database: 270.13.72/2337 - Release Date: 08/31/09
05:50:00

Andy

unread,
Sep 4, 2009, 11:45:48 AM9/4/09
to CenoPDF Support Group
Thanks, but I don't have those resources at my disposal. I was hoping
that the solution would be simpler than it is turning out to be. I'll
just keep plugging away at the javascript.

Andy

On Sep 1, 11:53 am, "CenoPDF Support" <supp...@lystech.com> wrote:
> Andy,
>
> The scenario you described is quite complicated. A potential solution could
> be like this:
> When user open the form, the question 1 and 2 are enabled while all other
> questions are disabled.
>
> After the user finishes question 1 and 2, some javascript could be triggered
> so that question 1 and 2 will be disabled and question 3 and 4 will be
> enabled and so on.
>
> This scenario also implies that user won't be able to come back to question
> 1 and 2 after 3 is changed.
> Also what if the user want to save the form without finishing the last
> question?
>
> We can make a demo for you if you want to go this way. But I have to ask you
> to purchase the Advanced Support as this will take us quite long time to
> work on:http://www.lystech.com/support.aspx
>
> By the way, I hope are aware that Adobe Reader does not allow your user to
> save the finished form unless you have Acrobat 8 or higher. See our FAQ 1:http://www.lystech.com/faq.aspx#q1
>
> Thanks,
>
> CenoPDF Supporthttp://www.lystech.com/
Reply all
Reply to author
Forward
0 new messages