1

I'm working on a project in which I've made a new webpart which inherits the CQWP. In the codebehind I send some additional values, which isn't present in the lists (meaning there are no columns containing these values) I'm displaying using this webpart.

Is it then necessary to use the @ symbol in order to fetch these values?

2 Answers 2

3

The CQWP renders the datatable columns as attributes of the row element so you would use the @ symbol to reference them in your XSLT as opposed to parameters or variables referenced using the $ symbol and elements referenced without any symbol

0

Are you passing additional parameters using the ModifyXsltArgumentList (or similar)? If so, just add the <xsl:param name="YourParamName"/> near the top of the xslt file and you can just get to the parameter names with $YourParamName.

4
  • I add an additional column to the datatable.
    – user2536
    Dec 29, 2011 at 10:53
  • Ah, understood. I've worked with code that does this only once before, but I can't quite remember if I needed to use @ or not. I know someone who might know better though...
    – James Love
    Dec 29, 2011 at 11:19
  • Is it possible of you to ask this someone? I'd really appreciate it
    – user2536
    Dec 29, 2011 at 12:40
  • Have done. He might have already blogged about this, so have a rake through his blog - platinumdogs.wordpress.com
    – James Love
    Dec 29, 2011 at 12:50

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.