Use PDIs? Take our 5-minute survey to help shape the PDI roadmap.

Making Field Read Only across all the sections of the Form

SatyanarayanaS
Tera Contributor

I have written a client script to make the field read only on certain conditions, it is making the field read only on the main form but I have the same field added to another section of the form, there it is editable, How to enforce the field as read only across all sections of the form?

Can anyone help me on this?

8 REPLIES 8

Ankur Bawiskar
Tera Patron

@SatyanarayanaS 

what do you mean by main form?

If that field is added at multiple places on form then making that read-only will make it readonly at all places

didn't get your question

💡 If my response helped, please mark it as correct and close the thread 🔒— this helps future readers find the solution faster! 🙏

Regards,
Ankur
Certified Technical Architect  ||  10x ServiceNow MVP  ||  ServiceNow Community Leader

The Main Incident Section and the same field in the Notes Section.

SatyanarayanaS_0-1787638014908.png

SatyanarayanaS_1-1787638024974.png

 

 

@SatyanarayanaS 

image is not clear

Regards,
Ankur
Certified Technical Architect  ||  10x ServiceNow MVP  ||  ServiceNow Community Leader

sristiG
Tera Expert

Hi,

Why not use UI policy/data policy rather than client script and see if it changes anything. ServiceNow recommends using UI policies rather than client scripts.