在Dynamics 365 for Outlook App中找不到实体错误 [英] Entity cannot be found error in Dynamics 365 for Outlook App

查看:73
本文介绍了在Dynamics 365 for Outlook App中找不到实体错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们在Dynamics 365 for Outlook App中收到以下错误:

We receive the following error in the Dynamics 365 for Outlook App:

找不到实体"{0}".指定一个有效的查询,然后尝试再次.

The entity "{0}" cannot be found. Specify a valid query, and try again.

这似乎与自定义代码相关联.

This appears to be associated with custom code.

推荐答案

事实证明,发生这种情况是因为调用了 Xrm.WebApi.retrieveMultipleRecords .如果您传入实体集名称(例如"accounts")而不是第一个参数所记录的实体逻辑名称(例如"account"),就好像在完整的Web客户端中一样.因为它在 ENTITY_SET_NAMES 常量中找不到.

It turns out this was happening because of a call to Xrm.WebApi.retrieveMultipleRecords. It appears as though in the full web client if you pass in the entity set name (ex. 'accounts') instead of the entity logical name as documented (ex. 'account') as the first parameter, then the web client just passes it through as it's not found in the ENTITY_SET_NAMES constant.

但是,在应用程序中,没有 ENTITY_SET_NAMES ,因此我猜测是按需进行元数据调用以查找实体集名称,但失败了,因为我们传递的是集名称而不是逻辑名称.

However, in the app, there is no ENTITY_SET_NAMES and so my guess is a metadata call is being made on demand to lookup the entity set name and failing because we were passing the set name instead of the logical name.

似乎已通过切换到逻辑名来纠正.

This appears to have been corrected by switching to the logical name.

这篇关于在Dynamics 365 for Outlook App中找不到实体错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆