?
Solved

Linking fields in a survey

Posted on 2006-06-06
3
Medium Priority
?
229 Views
Last Modified: 2013-12-18
OK so I have one question in my survey where if the user selects 'Not Applicable' , the rest of the buttons should be emptied and if the users selects the answers to the questions then the 'Not Applicable' button be emptied.

My original survey is very, very basic, and the question on the survey is

How would you rate 2nd level teams? And then I have 3 fields - Courtesy, Knowledge,Responsiveness, and these field are radio buttons with the options Very Good, Good, Poor, Very Poor.  I have another field at the end which is my not applicable one but they are not linked in any way!  And now they want it linked, I need help!

Thanks
0
Comment
Question by:Idltd
  • 2
3 Comments
 
LVL 22

Expert Comment

by:mbonaci
ID: 16842633
Hi Idltd,

1. Check the "Refresh fields on keyword change" option in second tab of field's properties (to trigger postrecalc event when change occurs).
2. In the form's PostRecalc event write the code that handles your thing.

Hope this helps,
Marko
0
 
LVL 22

Accepted Solution

by:
mbonaci earned 2000 total points
ID: 16842715
Idltd,
something like this:

Sub Postrecalc( Source As Notesuidocument )    
    If source.FieldGetText( "Courtesy" ) <> "" Then
        Call source.FieldSetText( "CourtesyNotApplicable", "" )
    End If
    .
    .
    .

End Sub


But wouldn't it be the simpliest solution to add "Not applicable" as the last option in every field?

Hope this helps,
Marko
0
 
LVL 18

Expert Comment

by:marilyng
ID: 16844197
Uh, why not use translation formulas in the fields themselves?

something like:  @if(FirstField="NA";"";CurrentFieldName);

Then for the first field:
  @if(thisField = "NA";@Do(
  @Set("theotherfield";"");
  @Set("theotherfield1";""));
  "";thisField)

Rough, but you get the idea.  People always forget to wipe a field when the check is unmarked, so the value stays on the form when it shouldn't.  Same thing for when a value unhides another field.  Use translation formulas to wipe the field value when the field is hidden and inactive.
 
0

Featured Post

Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I thought it will be a good idea to make a post as it will help in case someone else faces these issues. I trust this gives an idea how each entry in Notes.ini can mean a lot for the Domino Server to be functioning properly. This article discusses t…
Problem "Can you help me recover my changes?  I double-clicked the attachment, made changes, and then hit Save before closing it.  But when I try to re-open it, my changes are missing!"    Solution This solution opens the Outlook Secure Temp Fold…
When cloud platforms entered the scene, users and companies jumped on board to take advantage of the many benefits, like the ability to work and connect with company information from various locations. What many didn't foresee was the increased risk…
With just a little bit of  SQL and VBA, many doors open to cool things like synchronize a list box to display data relevant to other information on a form.  If you have never written code or looked at an SQL statement before, no problem! ...  give i…
Suggested Courses

830 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question