0

I'm using a CQWP(Content query web part) that fetch a calendar list and I want to filter my result (customqueryoverride - usign CAML). However, some fields from the calendar list are hidden to me.

I want to know all fields in my calendar list.

The solution I came up with was to use an identity transform XSL to display all my properties and their values and adding all fields to the CommonViewFields property.

<property name="CommonViewFields" type="string">
  EventDate,DateTime;EndDate,DateTime;fRecurrence,Boolean
</property> 

The issue I have is that I dont know the field name... Any wildcard I could use?(%%% and *** didn't work) Any other way of getting all the fields name would work too.

Note: It's to understand and play with recurrent events.

Kraz
  • 6,910
  • 6
  • 42
  • 70

3 Answers3

1

To print all available field names in CQWP the following XSLT could be used:

<xsl:for-each select="@*">
            Field Name :<xsl:value-of select="name()" />
</xsl:for-each>

It should be placed in ItemStyle.xsl inside template that is used to item rendering.

Vadim Gremyachev
  • 57,952
  • 20
  • 129
  • 193
1

Use the SharePoint 2010 Manager (http://spm.codeplex.com/) tool. It gives you a plethora of details about your SharePoint platform at all levels, right down to the fields in a list. It will give you all the field details, including the internal name you need to use for CommonViewFields.

user496539
  • 11
  • 1
0

Use tag for this, comment the main template in main XSL and add this as template match="/":

<xsl:template match="/ ">  
<textarea cols="50" rows="15" dir="ltr">
   <xmp><xsl:copy-of select="*"/></xmp> 
</textarea>

Now the CQWP will display the full query response XML