Unable to set a filed of the type "Script" read only
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-15-2024 03:38 AM
I have a form field of the type "script" and when I try to make the script read only using dictionary / UI policy the changes do not apply to this filed.
Please assist
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-15-2024 03:51 AM
Hi @Anubhuti Mittal ,
You can try "onLoad" client script or "onChange" client script based on your requirement and can try the below code -
g_form.setReadOnly('YourfieldName',true);
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-15-2024 04:18 AM
@Anirudh Pathak thanks for the reply.
The usual solutions are not working. I am using this field type " script" for the 1st time. Even making the field read only at dictionary level doesn't help.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-15-2024 04:37 AM - edited ‎07-15-2024 04:38 AM
Hi @Anubhuti Mittal ,
Create a read ACL on that field, in the role add 'admin' role so that no one else can view it.
Mark this as Helpful / Accept the Solution if this helps
Mark this as Helpful / Accept the Solution if this helps.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-15-2024 07:08 AM
Hi @Anubhuti Mittal
Try creating an ACL for the specific field if dictionary level/Ui policy restriction is not working.
Also, check is there something overriding this field to become read-only.
Regards,
Ratna Jyothi