Skip to main content

Notifications

Announcements

No record found.

Dynamics 365 Community / Forums / Sales forum / Retrieve the Optionset...
Sales forum
Suggested answer

Retrieve the Optionset Values from JSON and set that values in the Optionset

Posted on by 340

Hi All,

I need to remove Previous optionset values from Optionset. Then retrieve the optionset values from JSON based on some query and then set those values in the optionset. Adding option in optionset using Addoptions() not working.

Can any help on this issue.

Thanks in advance.

  • Suggested answer
    unizap Profile Picture
    unizap on at
    RE: Retrieve the Optionset Values from JSON and set that values in the Optionset

    Hi,

    Please check if the usage is proper as per -> https://docs.microsoft.com/en-us/dynamics365/customer-engagement/developer/clientapi/reference/controls/addoption 

    Also note that you can only add the option which is already defined in the field meta-data. If optionset values in JSON are not defined in the field then they will not be added to the field using the above method. You need to add those values in field definition first.

Helpful resources

Quick Links

Dynamics 365 Community Update – Sep 16th

Welcome to the next edition of the Community Platform Update. This is a weekly…

Announcing Our 2024 Season 2 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 290,353 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 228,251 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,148

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans