facebook

Dynamically change field to Read-Only and Back

💡
Our Forums Have Moved

For help with installation, bugs reports or feature requests, please head over to our new forums.
Genuitec Community on GitHub

  1. MobiOne Archive
  2.  > 
  3. Getting Help – General
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #343886 Reply

    Robert Gardner
    Participant

    I have a field that I want to be able to dynamically change to read-only and back to being input capable within my code. Does anyone have any insight on doing this?

    Also, I like (and use) checkboxes in my app… This may sound silly but is it possible to make these read-only. I like the look and feel of the checkbox and change it within my code. I may want to limit the users ability to change them since I manipulate them in my code. This second question is separate from the first one as noted in the post subject.

    Thanks,

    #343911

    Hi aviator,

    These snippets should help you to set/remove read only attr for your textfields:

    Set:

    $("#m1-screen-textField1").attr("readonly","readonly");
    

    Remove:

    $("#m1-screen-textField1").attr("readonly",false);

    For the read only of checkbox question, I haven’t done it, will do some test and consult dev team if necesary and will follow up with you as soon as I have more information.

    #343916

    Robert Gardner
    Participant

    Thank you for your prompt reply.. This helps

Viewing 3 posts - 1 through 3 (of 3 total)
Reply To: Dynamically change field to Read-Only and Back

You must be logged in to post in the forum log in