List/Grid Tag Archives: XPath

#PSTip Using XPath in PowerShell, Part 6

#PSTip Using XPath in PowerShell, Part 6

When we analyze XML documents with XPath we may need information about number of certain items. For example, we can have an XHTML document with several tables and we can… Read more »

#PSTip Using XPath in PowerShell, Part 5

#PSTip Using XPath in PowerShell, Part 5

XPath has one big disadvantage–it’s case sensitive. Unlike regular expressions, there is no way to “turn it off”. But there is a way around it. To make part of the… Read more »

#PSTip Using XPath in PowerShell, Part 4

#PSTip Using XPath in PowerShell, Part 4

Filtering using XPath is not limited to queries that make sure that existing value is equal to value that we are interested in. If the data within XML is numeric,… Read more »

#PSTip Using XPath in PowerShell, Part 3

#PSTip Using XPath in PowerShell, Part 3

Filtering data with XPath works very well even if we need more complex filters that require information from different levels in the XML document. Perfect example of such document is… Read more »

#PSTip Using XPath in PowerShell, Part 2

#PSTip Using XPath in PowerShell, Part 2

XPath can be used to apply ‘filter left’ philosophy to XML documents. For example we can find any h1 element with ‘title’ id using the following syntax: Note: You can… Read more »

#PSTip Using XPath in PowerShell, Part 1

#PSTip Using XPath in PowerShell, Part 1

This is the first tip in a series of Select-Xml/XPath tips. Working with XML documents in PowerShell is relatively easy. For most things it is enough to read XML file… Read more »

© 2017 PowerShell Magazine. All rights reserved. XHTML / CSS Valid.
Proudly designed by Theme Junkie.