Skip to main content
johnh91582287
Participant
October 19, 2017
Question

One Field shows results if other fields have been used.

  • October 19, 2017
  • 0 replies
  • 209 views

I have a field (Field1) that gets information from a calulated field (Field2) fed by three other section group fields (fieldgroupTotal-1,fieldgroup total-2, fieldgroup Total-3). Everthing works well.  I want field 1 to only show something once all THREE fieldgroup totals have a number.

var v = this.getField("Total_Score").valueAsString;  if (v=="") event.value = "";

else {

    var score = Number(v);

    if (score>=3 && score<=7) event.value = "Low";

    else if (score>=8 && score<=12) event.value = "Medium";

    else if (score>=13 && score<=15) event.value = "High";

    else if (score<=0) event.value = "Not Started";

}

This Script works great, I just now need it to only work if all three groups have had an enterie inside of that group selected.

This topic has been closed for replies.