Select to view content in your preferred language

C# CodedValueDomain.GetName

557
0
11-19-2018 11:29 AM
MikeRatcliffe
Frequent Contributor

I populate a combobox with CodedValueDomain.GetName.

I get varied results with partially-populated coded value descriptions.

else if (DMN is CodedValueDomain)
    {
         CodedValueDomain CodedValueDMN = (CodedValueDomain)DMN;

         FieldType fieldType = CodedValueDMN.GetFieldType();

         SortedList<object, string> codedValuePairs = CodedValueDMN.GetCodedValuePairs();

         IList<string> codedlist = codedValuePairs.Values;

         foreach (string s in codedlist)
         {
             Invoke(new MethodInvoker(async delegate { MnlSrchPlldwn.Items.Add(await QueuedTask.Run(() => CodedValueDMN.GetName(s))); }));‍‍‍‍‍‍‍‍‍‍‍‍
         }‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍
     }

attached:

results,

actual coded value descriptions

There must be a way to get the complete list of coded value descriptions into my combobox...  Help?

0 Kudos
0 Replies