Read-Only After Submit

Khalid9030
Tera Contributor

Hello Team,

 

Need help. 

 

When we click the Submit button, the form redirects to the list view, and all fields should become read-only in both the list view and the form view. However, when the user clicks the Save button, all fields remain editable until the Submit button is pressed."

 

How we achieve this ? Please assist me 

9 REPLIES 9

Amit Pandey
Kilo Sage

Hi @Khalid9030 

 

You can use the client script and UI Action to achieve this.

 

Regards,

Amit

@Amit Pandey 

Thanks for the reply. 

I don't believe this can be achieve through client script and UI action. 
If you have already done, could you please share the code ? 

Dr Atul G- LNG
Tera Patron
Tera Patron

Hi @Khalid9030 

 

Why do you want two 2 different behaviours on the same form? In both cases, records get inserted into the database. You need to write UI policy/client script to make it read-only but in that case, what should be the identifier? Bcz when a from loaded, the state is New and even when the record gets saved then also it in new state. 

*************************************************************************************************************
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.

Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/atul_grover_lng [ Connect for 1-1 Session]

****************************************************************************************************************

@Dr Atul G- LNG 

"Actually, this is our client requirement. If it's not possible, what can we suggest as an alternative method?"