导出导入Web部件无法正常工作 - 此查询未返回任何项目。要配置此Web部件的查询,请打开工具窗格

时间:2011-04-26 09:16:58

标签: .net sharepoint sharepoint-2007

我将内容查询Web部件拖到我的页面,然后它显示我网站中的三个页面。我将它导出到一个文件并保存。

然后我在保存的Web部件文件中更改以下内容: -

<property name="CommonViewFields" type="string" />

<property name="CommonViewFields" type="string" >EditorRemarks</property>

<property name="DataFields" type="string" />

<property name="DataFields" type="string" >EditorRemarks</property>

然后,当我删除原始Web部件并在上面添加导入的Web部件时。我收到以下错误: -

此查询未返回任何项目。要配置此Web部件的查询,请打开工具窗格。

我的内容类型中有“EditorRemarks”列。

我对sharepoint完全不熟悉。请告诉我如何解决此错误?

1 个答案:

答案 0 :(得分:0)

CommonViewFields的格式为Internal Name,Type。如果您有多个字段,则需要用分号分隔。此外,您不需要更改DataFields属性。

有关CommonViewFields的更多信息,请参阅Customizing the Content Query Web Part and Custom Item Styles的步骤17。