Quantcast
Channel: Windows PowerShell forum
Viewing all articles
Browse latest Browse all 21975

XPath predicate on wildcard

$
0
0

I am trying to get a (for me!) complex XPath expression working, and having trouble. If I use this it finds all nodes in the Arch Package Set, including Removals.

$SetExpression = "/Definitions/PackageSets/PackageSet[@id='Arch']/*"

But if I do this it returns nothing, rather than returning the two Rollout nodes that are there.

$SetExpression = "/Definitions/PackageSets/PackageSet[@id='Arch']/*[Name!='Removal']"

So, is it not possible to apply a predicate to a wildcard?


Viewing all articles
Browse latest Browse all 21975

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>