为了获取OptionSet信息,我们可以发出请求:
// Create the request
RetrieveAttributeRequest attributeRequest = new RetrieveAttributeRequest
{
EntityLogicalName = Contact.EntityLogicalName,
LogicalName = "new_string",
RetrieveAsIfPublished = false
};
// Execute the request
RetrieveAttributeResponse attributeResponse =
(RetrieveAttributeResponse)_serviceProxy.Execute(attributeRequest);
Console.WriteLine("Retrieved the attribute {0}.",
attributeResponse.AttributeMetadata.SchemaName);
有没有办法在 crm 2016 中使用 Odata 请求来执行此操作?
最佳答案
是的,你可以,Use the Web API with Dynamics 365 metadata .
我建议您查看 OptionSetMetadata,位于 [Organization URI]/api/data/v8.2/GlobalOptionSetDefinitions
关于c# - 如何通过Odata实现RetrieveAttributeRequest?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/44638924/