How can we hide a specific Subcategory option from the Subcategory choice list on the Incident form

Ria
Tera Contributor

We have a business requirement on the Incident form to hide one specific Subcategory option when the Category is set to Application. Both fields (Category and Subcategory) are standard choice fields on the Incident table.

We cannot deactivate this Subcategory choice at the dictionary level because:

  • The same Subcategory is still needed and actively used in other forms and processes, and
  • We are creating a new Catalog Item where this Subcategory must remain visible under the Application category by default.

Because of this, the Subcategory must remain active, but it should be hidden only on the Incident form when Category = Application. All other Subcategory choices must remain available.

Can anyone advise on the best approach to achieve this?

13 REPLIES 13

@Ankur Bawiskar

I already tried using this script, but even after selecting the ‘Application’ category, the option still remains visible under Subcategory. (refer to the screenshot)

@Ria 

since subcategory must be dependent on category this removeOption won't work

💡 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

@Ankur Bawiskar 

Yes, it is dependent on the Category field. Could you please let me know if there is any alternative approach to achieve this?

@Ria 

when you are writing your onChange client script it takes some time to bring dependent subcategories

try to give some timeout and see if that works

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