1

I have a CQWP that is pulling all recently added list items as a display of, "What's new" on a site collection. The problem I have encountered however is that the CQWP's query has to have a default list type that it pulls through information for.

Is it possible to pull through list items from Document Libraries as well as announcement lists and custom lists?

1

You will need to use QueryOverride property of CQWP. For example:

<property name="QueryOverride" type="string"><![CDATA[<Where><Or><Eq><FieldRef Name="ContentType"/><Value Type="Computed">Company Announcements</Value></Eq><Eq><FieldRef Name="ContentType"/><Value Type="Computed">Announcement</Value></Eq></Or></Where>]]></property>

In your case you will need to specify content type of document library and announcement. For more information on how to customize CQWP, please refer this.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.