Want to Populate Choices in the Category and Sub-Category Fields of Case form

Balaraju K B
Tera Expert

Hi Team,

I have two drop-down fields category and sub-category on case form.I want to add choices to these two fields both fields are drop-down.

  • For Category i have 4-choices For example : A,B,C,D is the 4 categories.
  • If Category selected is 'A' then For Sub-category there are some choices to be added.
  • Similarly if category selected is 'B' then For 'B' category there will be some choices in the Sub-category drop-down.

Let me know the script for this ???

 

Thanks in Advance

Balaraju

 

1 ACCEPTED SOLUTION

Ankur Bawiskar
Tera Patron
Tera Patron

@Balaraju K B 

you can configure the dependent values for the drop down

Sub-category choice values will have dependent value as per category value

refer links below

Incident categories and subcategories

Regards
Ankur

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

View solution in original post

7 REPLIES 7

Dhananjay Pawar
Kilo Sage

Hi,

No need to have script for the,

If you check incident category and sub category functionality you will understand.

You need to set dependent fields for subcategory.

Thanks,

Dhananjay.

Process.

 

Right click on subcategory -> configure dictionary -> under dependent value section select category field as dependent field(check attached screenshot)

find_real_file.png

 

Then under choice related list add total choices and set dependent values(check attached screenshot)

find_real_file.png

First Category Itself Contains 47 subcategory choices is it good to use deependent field?

No i think that's why looking for client script.

Hi,

You can use and it is good. try to use OOB functionality instead script. If you go with script still you need to write code for all those subcategory choices of 4 category and thats not good.