Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
I'm using the following code - I'm pretty sure it was working but I can't figure out why it isn't now!
var nodeList= new List<Node>();var propertyValue = "<MultiNodePicker><nodeId>1089</nodeId><nodeId>1101</nodeId></MultiNodePicker>";nodeList= uQuery.GetNodesByXml(propertyValue);
but nodeList.Count() is equal to 0...
It's the standard MultiNodePicker XML as far as i'm aware.
The code snippet looks correct to me - XML is valid for MNTP. Question is - are the node ids correct? As in are they actually published nodes?
Let us know, curious if there is anything else at play here.
Yeah they're all published media nodes. I've played around with different number of nodes in the MNTP but i'm stumped.
Now I'm creating new properties on other pages to try it out there, see if I get the same problem!
This is nuts. I'm using it elsewhere on exactly the same site, the equivalent of
nodes = uQuery.GetNodesByXml("<MultiNodePicker><nodeId>1083</nodeId></MultiNodePicker>");
and it's working fine!
Joel, you're gonna kick yourself! ;-)
nodeList = uQuery.GetMediaByXml(propertyValue);
The other one (GetNodesByXml) gets content nodes only.
hahaha no way!
I just assumed that content node and media node inherited from just plain node...
permission to update ucomponents codeplex documentation page?
I'm currently on v2.1, notice GetMediaByXML is 2.2+. Best to go 2.2 or 3.0? (4.7 site)?
Yeah, just noticed "GetMediaByXml" was added in v2.2 beta ... better to use v3.0 (which is really v2.2 ... we've just bumped the version number coz waaay to many people were using the v2.2 beta - difficult to keep track of).
If you want to edit the CodePlex doco - let me know your CodePlex username, I can add you as an editor. :-D
All sorted now. Was a very quick fix. 3.0 all the way!
codeplex username is the same as here there and everywhere :)
Probably won't be any huge additions, just a note when I find something out like this.
Hey Joel, was going to guess your username, but ya never know! :-)
Welcome to the uComponents team! (Sounds scary huh?! We'll celebrate next umBristol meetup)
is working on a reply...
Write your reply to:
Image will be uploaded when post is submitted