问题
I am creating a web resource which will populate a HTML table with tasks
I was trying to get the PriorityCode
of a tasks. But I don't know how to get value/text from a OptionSet
.
This is a screen shot :

Thanks
回答1:
You have query metadata, see this various methods to do that:
- http://crmdude.wordpress.com/2009/02/04/performing-a-javascript-web-service-call-to-the-metadata-service/
- http://guruprasadcrm.blogspot.com.au/2011/07/retrieving-optionset-lable-data-using.html
- http://mileyja.blogspot.pt/2011/08/retrieve-installed-language-packs-in_19.html
回答2:
I would start with the AttributeFormat member. Check to see if this member contains a key for your OptionSet; if it does not, then Pedro's advice is probably the next place I would go.
来源:https://stackoverflow.com/questions/15479487/how-to-get-value-text-from-a-optionset