Web Survey with Rated Answers

I’m a new Lotus developer and I am working on a web survey to be completed by our employees. I have questions which ask that multiple items be rated on a scale of 1 to 5. I have completed those fine using radio buttons with 5 choices one per line. My question is how to handle a question where I have a similar rating system (1 to 3) but the person is to only select the top three challenges and then rate only those three using this scale? In other words, they are not to rate any of the other challenges. Currently, my form allows them to rate all the items using the radio button values.

Thank you in advance!

Subject: Web Survey with Rated Answers

A checkbox field to select the top three and hide-when formulas to control that only those three’s radio buttons show up.

Subject: RE: Web Survey with Rated Answers

Thanks Bruce! I understand what you are saying in concept but I can not get it to work.

First,I’m having trouble with what formula to use in the hide-when for each of the rating fields and how I will refresh the survey on the web so these fields may evaluate the checkbox field(Javascript?). Secondly, I need to limit the user to select three and only three of the items on the checkbox list.

Thanks for your help!

Subject: RE: Web Survey with Rated Answers

First off, I apologize for not reading the word “web” in your subject; my response would probably have been a bit longer. (Then again, not necessarily; I tend to intially post a short response since the majority of posters never respond back to an answer.)

There are lots of ways to address developing this, from simple and somewhat clumsy to involved and prettier.

The least amount of work, but the poorest performance on the web, would be to use hide-whens as I indicated. More work might entail using some combination of javascript, tags, computed subforms, multiple forms, query_string parameters, dynamically-generated html, etc.

Since you’re a new developer, I’d suggest compromising between complexity and performance. One option along that line:

  1. Enable “Refresh fields on keyword change” on the checkbox field. (It sounds like there’s only one of these. NOTE: This is the poor performance part; every click on the checkbox fires a post-and-reload round trip between browser and server.)

  2. Add a hidden, computed for display number field (I’ll call it NumSelected) below the checkbox and above the dependent radio buttons which computes to @elements(CheckBoxFieldName). (Hidden fields on the web require that the form’s “Generate HTML for all fields” property be set.)

  3. Each radio button field’s hide-when would then be similar to

(NumSelected != 3) | @isnotmember(“Relevant chkbox choice”; CheckBoxFieldName))

This will prevent any of the dependent radio button fields to display until 3 and only 3 are selected in the checkbox, and only those three chosen will display. (To prevent errors in aggregate data analysis later on, you’ll also probably want translation formulas for the radio button fields which look like

@if(@ismember(“Relevant chkbox choice”; CheckBoxFieldName); @ThisValue; “”)

This will clear any extraneous radio button field values the user enters before changing their mind about which ones to fill in after all. The downside of this is that unchecking and then re-checking a choice will cause that radio button to forget what you just chose in it.)

To lose the performance hit associated with enabling the checkbox field’s “Refresh fields…” property, there are a lot of more-involved options, but you might want to see if this works for you before delving into something more involved.

Subject: RE: Web Survey with Rated Answers

Thanks so much Bruce! It works great as far as I’m concerned but if the customers do not like it, or I run into any problems, I will let you know. I also appreciate your compromise between complexity and performance to meet my skill level.

Thanks again,

Dennis