1 Reply Latest reply on Nov 9, 2015 2:46 PM by alivecycle69

    how do i create a sub form when i make a selection from a radio button.

    BobbyPSCH Level 1

      (explanation) the form has 2 option, when i select either i want to see only field relative to that selection

      Example.

      New user  (Radio button)

      this will give me field that are only applicable to a new user

      User modification (radio Button)

      this will give me fields applicable to modify a user account

      this can be in the form of a new page or hide or unhide certain field.

        • 1. Re: how do i create a sub form when i make a selection from a radio button.
          alivecycle69

          You will need to have 2 subforms. When you click the radio button, it will hide one of the subforms and show the other. By default, the forms would both be hidden. In the java script for the "change" event of the radio-button, hide one and show the other. Below should help you get started.

           

          Nothing selected:

           

          "New User" selected:

           

           

          "Existing User" selected:

           

           

          Java for radio-button change event:

          switch(this.rawValue) {

              case '1':

              form1.frmMain.frmNewUser.presence = "visible";

              form1.frmMain.frmExistingUser.presence = "hidden";

              break;

              case '2':

              form1.frmMain.frmNewUser.presence = "hidden";

              form1.frmMain.frmExistingUser.presence = "visible";

                  break;

           

          }