idm
idm

Reputation: 1748

Valid sitecore query - wrong xpath query

why does valid sitecore query: /sitecore/content/#My tree#/MyItems/*[contains(@@name, 'thename')] in xpath results to: Expression must evaluate to a node-set. Using sitecore developer center / xpath builder. Wanted to modify the query to use in code. Thanks,

Upvotes: 2

Views: 866

Answers (1)

Adam Hopkinson
Adam Hopkinson

Reputation: 28795

This is a Sitecore Query, and isn't valid xpath. You can only use it in certain places within Sitecore (such as field sources) as well as within CodeBehind files.

There's a PDF document explaining it on the SDN

Upvotes: 2

Related Questions