'Automatic maths multiple lines Powershell
I have an xml file that resembles like below:
<rule id="110001" level="5">
<if_sid>110000</if_sid>
<field name="test1</field>
<description>test1</description>
</rule>
<rule id="110001" level="5">
<if_sid>110000</if_sid>
<field name="model.name">test2</field>
<description>test2</description>
</rule>
<rule id="110001" level="5">
<if_sid>110000</if_sid>
<field name="model.name">test3</field>
<description>test3</description>
</rule>
The value 110001 should be added by 1 on the line rule id each time. Is there a way to accomplish this in powershell? It should be like 110002,110003,110004 and so on.
Thanks in advance
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
