Join the #BuildWithBuildAgent Challenge! Get recognized, earn exclusive swag, and inspire the ServiceNow Community with what you can build using Build Agent.  Join the Challenge.

How to hide a field on form section?

Srinivas Goud K
Tera Contributor

Hi All,

My requirement is to hide a field in "input section" on the form. I tried with UI policy but it is not working, is there any other way with form sections? any inputs please

find_real_file.png

In the above pic I need to hide "Service" field on Input Section how can i achieve that?

 

1 ACCEPTED SOLUTION

Ankur Bawiskar
Tera Patron
Tera Patron

Hi,

it's not a field.

It's a variable.

So you will require catalog UI policy.

If it's generated from record producer then create catalog UI policy which Applies on Target Record

If it's RITM form then create catalog UI policy which Applies on Requested Item

Regards
Ankur

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

View solution in original post

4 REPLIES 4

Ankur Bawiskar
Tera Patron
Tera Patron

Hi,

it's not a field.

It's a variable.

So you will require catalog UI policy.

If it's generated from record producer then create catalog UI policy which Applies on Target Record

If it's RITM form then create catalog UI policy which Applies on Requested Item

Regards
Ankur

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

@Srinivas Goud Kadali 

Glad to know that my comment worked.

Please mark response helpful as well.

Regards
Ankur

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

Harish KM
Kilo Patron
Kilo Patron

Hi you can create a UI policy with Applies on Target table checkbox to true or

with a onload client script with the below line

g_form.setVisible("variables.variablename",false); //variables.variablename for example variables.service

Regards
Harish

Pavankumar_1
Mega Patron

Hi,

if you are creating record using the record producer.

Then go the catalog item use catalog UI Policy or catalog client script to hide the variable.

1. Try to get it through the Catalog UI policy and hide your variable.

find_real_file.png

2. You can create the catalog client script and use below script to hide variable.

g_form.setDisplay("variables.variablename",false); 

 

Thanks,

Pavankumar

 

If it helps please click Accept as Solution/hit the Thumb Icon.
ServiceNow Community MVP 2024.
Thanks,
Pavankumar