4 Replies Latest reply: Apr 11, 2013 7:20 AM by PhHein RSS

    JavaScript Error : Can't move focus to the control because it is invisible,

    815519
      I have one JSP page in my project where i am putting all input to save personal details of a person.
      This personal details header contains button(to collapse or expand).

      I input all details and save. It works fine but when i collapse the header and name, age etc are not visible.
      Only Save and cancel button is visible. so i click on save and following javascript error show up :


      Can't move focus to the control because it is invisible, not enabled, or of a type that does not accept the focus.

      In case of expand mode,If there is any error while providing input in text boxes , i have given pop up to display that like " Name field is mandatory " and control focus to that field again. it works fine.

      In case of collapse, as fields are not visible and if i directly click on save button. Pop up is displayed as usual "Name field is mandatory" but it pop up again javascript error
      "Can't move focus to the control because it is invisible, not enabled, or of a type that does not accept the focus."

      Please let me know how to reolve this?