Add this snippet of code to the Item Style (Style Sheet) file to render the names of the fields being passed to the Content Query Web Part (CQWP). Note that this code will be temporary. You don't want to leave this in the finished Item Style!

<xsl:template name="RenderFieldsBeingPassed" match="Row['RenderFieldsBeingPassed']" mode="itemstyle">
<xsl:for-each select="@*">
   P:<xsl:value-of select="name()" />

Save the file. Return to the site (in the browser) and refresh the page. Open the Web Part Tool Pane for the CQWP and expand Presentation. Then under Styles change the Item Style to the new custom style (RenderFieldsBeingPassed) in the drop down. Select Apply.

The CQWP will now list out all of the fields that are being passed.

Your comment will be posted after it is approved.

Leave a Reply.