How to make the "Custom" variable type as Mandatory for Record Producer

Kruthika BM
Tera Contributor

Hi Everyone,

 

We have the requirement where to set the Custom Variable type as mandatory for the record producer. I have tried with Catalog UI policy, but its not working.

Can anybody please help me to solve the issue?

 

Thanks in Advance!!

 

Regards,

Kruthika

 

2 REPLIES 2

Dan O Connor
ServiceNow Employee
ServiceNow Employee

Hi @Kruthika BM , can you share a screenshot or some information and I am sure we can figure it out 🙂 

 

You can set Record Producer variables to be mandatory directly (in the field setup) or as you say, you can use a UI policy 

Peter Bodelier
Giga Sage

Hi @Kruthika BM,

Are you using the variable in the portal or in the backend?
Or in other words, are you using a widget or a macro?

Since this is not a standard variable, I think you will have to create your own logic in the widget.
If you want to validate it before submission of the form, you are probably going to need a hidden variable, which can be filled by the widget/macro. Then in onSubmit Client script, you could validate if the widget/macro has been correctly filled.


Help others to find a correct solution by marking the appropriate response as accepted solution and helpful.