I need to get the following value from the XML file.
<container>
<name>ServerName</name>
<type>Node1</type>
<applications>
<application Name="App1">
<Attribute1>A</Attribute1>
<Attribute2>B</Attribute2>
</application>
<application Name="App2">
<Attribute1>C</Attribute1>
<Attribute2>D</Attribute2>
</application>
<application Name="App3">
<Attribute1>E</Attribute1>
<Attribute2>F</Attribute2>
</application>
</applications>
</container>
In order to get App3 Attribute1 I found the following XPATH expression:
/container/applications/application[@Name='App3']/Attribute1
The problem is that I don't know how to use the above xpath expression in Powershell.
Thanks!