2 Replies Latest reply on Mar 5, 2015 1:34 PM by gkaiseril

    make form fields Read only without buttons

    omanbux Level 1

      Hi, I want to make my form fields read only using JavaScript. i have found bellow codes & it's work.

      My problem is, buttons i don't want to make read only. i have submit button in my form. other than submit button

      other all the fields i want to make read only.. so pls help me to do that. thanks..


      // make all fields in a form read only;

      var oField; // variable for field being processed;

      // loop through the form fields;

      for (var i = 0; i < this.numFields; i++) {

      // process each field name;

      oField = this.getField(this.getNthFieldName(i)).readonly = true;



      PDF Form javascript for making readonly field by using button