Aaron Cain
asked on
vbscript to read xml file and write to registry
I am looking to get a vbscript to read an the attached XML file
xml version="1.0" encoding="UTF-8"?>
<HPDOM>
<diagModule>
<_1>
<TestResult>
<_3>6144</_3>
<_4>The Battery health is the indicator of how well the multiple cells for the battery are charging and discharging. A Good Status indicates the battery is functioning properly.</_4>
<_5>9GBWTK-5L2617-WPQC2J-C 0CX03</_5>
<_6>DesignCapacity=5600,Fu llChargeCa pacity=534 2,Remainin gCapacity= 5342,MaxEr ror=0,Cycl eCount=21, Temperatur e=32,Termi nalVoltage =12810,Cur rent=0,Des ignVoltage =11100,Bat teryManufa ctureName= HP,Status= 224,CellVo ltage1=0,C ellVoltage 2=4267,Cel lVoltage3= 4270,CellV oltage1=42 74,Battery ACPower=1, BatterySup portedCoun t=1,Serial Number=005 84 2011/02/09,Source=1,Table= 0,SubTable =0</_6>
</TestResult>
</_1>
</diagModule>
</HPDOM>
and export the data for the following :
DesignCapacity=5100
FullChargeCapacity=4934
RemainingCapacity=3904
CycleCount=114
Current=2611
DesignVoltage=10800
Status=128
CellVoltage1=4122
CellVoltage2=4110
CellVoltage3=4115
BatteryACPower=1
SerialNumber=07415
Into corresponding registry keys
xml version="1.0" encoding="UTF-8"?>
<HPDOM>
<diagModule>
<_1>
<TestResult>
<_3>6144</_3>
<_4>The Battery health is the indicator of how well the multiple cells for the battery are charging and discharging. A Good Status indicates the battery is functioning properly.</_4>
<_5>9GBWTK-5L2617-WPQC2J-C
<_6>DesignCapacity=5600,Fu
</TestResult>
</_1>
</diagModule>
</HPDOM>
and export the data for the following :
DesignCapacity=5100
FullChargeCapacity=4934
RemainingCapacity=3904
CycleCount=114
Current=2611
DesignVoltage=10800
Status=128
CellVoltage1=4122
CellVoltage2=4110
CellVoltage3=4115
BatteryACPower=1
SerialNumber=07415
Into corresponding registry keys
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.