Frequent Visitor.

CM 9.4 UDF value fetching from API

I am connecting to the CM 9.4 Service API in my .Net code and using the GetPropertyOrFieldValue method to fetch a UDF value that I set from the web client.

Although the example given in the API site says that GetPropertyOrFieldValue("UDFName") should fetch the value, my code still returns null. Below is the code that i am running

RecordFind request = new RecordFind()
Id = 1656047.ToString(),
Properties = new PropertyList("F******DocId"),
PropertyValue = PropertyType.Both,
StringDisplayType = StringDisplayType.ViewPane

var response = trimClient.Get(request);
Record record = new Record();
record = response.Results[0];

var F**DocId = record.GetPropertyOrFieldValue("F******DocId");

The above variable is evaluated to null. Is there something that I am missing?

Also, when i check the Fields Property in the Locals Window, I can see that the UDF is getting properly evaluated from the value set by me, but the method provided doesn't seem to fetch that data.




The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.