7 Replies Latest reply on Mar 9, 2016 6:17 PM by dustind38670637

    I am having trouble with radio buttons and getting them to show/hide fields.

    dustind38670637

      So the code below works but the for loop when entering Choice 1 doesnt stay between fields 57-119 it hides all the fields in my document. any help would be apreciated. choice 2 works great.

       

       

       

       

       

      function updateFormField()

      {

         var v = this.getField("Group50").value;

        

         if (v == "Choice1") {  

           for (var i=57; 57<=i<=119; i++) ;

                this.getField(this.getNthFieldName(i)).display = display.hidden;

                   

                                                  }

                              }    

       

       

         else if (v == "Choice2")

         {

            this.getField("Text58").display = display.hidden;

            this.getField("Dropdown66").display = display.visible;

            this.getField("Text67").display = display.visible;

         }

       

      }

       

      updateFormField();