I have an xml file, test.xml that looks like this:
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<PLS Version="2.0" Title="DocTitle">
From the PS cmdline I do:
[xml]$var = get-content .test.xml
The question is, how can I easily reference the text 'Record2' and place it in a variable for instance?
I currently reference this text as $var.PLS.Record.Field.'#text' and this way I can place it in a variable, but I would rather access it on the actual field name, 'FieldName1'. I tried a million things and googled til I fell asleep.
Imagine I know a record name and want to access this records' note?
Thanks for any help!