(imported topic written by jgolembi)
I have an XML document that I will need to parse.
The document itself is pretty sparse.
It looks like this:
<ActionList TemplateVersion=
"1.7.0.1" EngineVersion=
"1.7.0.6"> <Action> <ActionName>Bootstrap-ConfigureTimeZone</ActionName> <ActionData> </ActionData> <ActionStatus>DONE</ActionStatus> </Action> <Action> <ActionName>Bootstrap-ConfigureNetworking</ActionName> <ActionData> </ActionData> <ActionStatus>DONE</ActionStatus> </Action> <Action> <ActionName>Bootstrap-JoinDomain</ActionName> <ActionData> </ActionData> <ActionStatus>DONE</ActionStatus> </Action> <Action> <ActionName>ProvisionVM</ActionName> <ActionData>4096</ActionData> <ActionStatus> </ActionStatus> </Action> </ActionList>
I have used the following lines of relevance:
{CODE}q: (node values of child nodes of selects “/ActionList/Action/ActionStatus” of it as string) of xml document of file “c:\khn00p02.xml”
A: DONE
A: DONE
A: DONE
q: (node values of child nodes of selects “/ActionList/Action/ActionName” of it as string) of xml document of file “c:\khn00p02.xml”
A: Bootstrap-ConfigureTimeZone
A: Bootstrap-ConfigureNetworking
A: Bootstrap-JoinDomain
A: ProvisionVM
A: AddVMDisk
A: AddVMDisk
A: PerformHandoff
A: ConfigureTimeZone
A: ConfigureNetworking
A: CreatePartition
A: CreateMountPoint
A: HardwareStartingPoint
A: CreateExampleDirectoryStructure
A: ConfigureDesktop
A: JoinDomain
A: ConfigureOSPrerequisites
A: Configure2008OSFeature
A: Configure2008OSFeature
A: Configure2008OSFeature
A: InstallSQL2008R2-Express
A: InstallAV
A: Install7Zip
A: InstallThirdPartyTools
A: InstallJava
A: ConfigureiSitePrerequisites-4x
A: InstalliSite
A: ConfigureEventLogSecurity
A: ConfigurePostrequisites
I would like an output from the attached XML document to look like:
A: Bootstrap-ConfigureTimeZone - DONE
A: Bootstrap-ConfigureNetworking - DONE
A: Bootstrap-JoinDomain - N\A
A: ProvisionVM - N\A
A: AddVMDisk - N\A
A: AddVMDisk - N\A
A: PerformHandoff - N\A
A: ConfigureTimeZone - N\A
A: ConfigureNetworking - N\A
A: CreatePartition - N\A
A: CreateMountPoint - N\A
A: HardwareStartingPoint - N\A
A: CreateExampleDirectoryStructure - N\A
A: ConfigureDesktop - N\A
A: JoinDomain - N\A
A: ConfigureOSPrerequisites - N\A
A: Configure2008OSFeature - N\A
A: Configure2008OSFeature - N\A
A: Configure2008OSFeature - N\A
A: InstallSQL2008R2-Express - N\A
A: InstallAV - N\A
A: Install7Zip - N\A
A: InstallThirdPartyTools - N\A
A: InstallJava - N\A
A: ConfigureiSitePrerequisites-4x - N\A
A: InstalliSite - N\A
A: ConfigureEventLogSecurity - N\A
A: ConfigurePostrequisites - N\A
{code}
The problem is that most of the ActionStatus nodes have no data in them until that action is either running or COMPLETE.
Any good ideas?
-John G