Powershell: XPath cannot select when element has “xmlns” tag?
问题 I've got a very simple xml, as below: <?xml version="1.0" encoding="utf-8"?> <First> <Second> <Folder>today</Folder> <FileCount>10</FileCount> </Second> <Second> <Folder>tomorrow</Folder> <FileCount>90</FileCount> </Second> <Second> <Folder>yesterday</Folder> <FileCount>22</FileCount> </Second> </First> Then I have a powershell script to select "Folder" element: [xml]$xml=Get-Content "D:\m.xml" $xml.SelectNodes("//Folder") It outputs: #text ----- today tomorrow yesterday No problem. But if I