on 11-12-2009 8:54 AM
Hi all,
I'm new to Adobe Forms and am trying to permanently lock text fields after a "Lock" button is clicked.
in my Click Event i placed the following :
data.subForm1.EMPFIRST.access = "readOnly";
data.subForm1.EMPLAST.access = "readOnly";
After the button is clicked, the text fields become un-editable which is correct, but when the Form is saved,
then re-opened, the saved values appear but are editable.
Any help would be greatly appreciated,
Miguel
Hi
Try This
Create one flag for the read only mode Field_edit and assign the value during click event. In the layout ready or in form ready check the flag and assign read only.
//button click event
data.subForm1.EDITFLAG.rawValue = "X";
//in Form Ready
if(data.subForm1.EDITFLAG.rawValue == "X"){
data.subForm1.EMPFIRST.access = "readOnly";
data.subForm1.EMPLAST.access = "readOnly";
}
Kind Regards
Mukesh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks guys,
Problem solved. I thought the solution involved something to do with permanently changing the XML file.
Thanks again,
Miguel
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
The same code which you have placed in "Click" Event do also place it in "Form Ready" or "Initialize" Event then it will work. But place that code based on some condition otherwise your fields will become readonly.
Regards
Pradeep Goli
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You can experiment with digital signatures which allow locking the fields.
Also you can try debug what happened using the postSave event for scripting.
Maybe you can try a read-only field which is read-only all the time (static from design time) which you change using script and hope the "read-only" attribute will remain unchanged.
This is what I would try. Have a nice day, Otto
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
82 | |
10 | |
10 | |
9 | |
6 | |
6 | |
5 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.