Stack Overflow Asked on December 30, 2021
My file has thousands of line like this
[enter image description here][1]
`<userdata ID="11010014" PRI="1" Locator="Class_abc" DATA="5 "/>
<userdata ID="11010014" PRI="1" Locator="Class_abcde DATA="5 "/>
<userdata ID="11010014" PRI="1" Locator="Class_ab" DATA="5 "/>
<userdata ID="11010014" PRI="1" Locator="Class_primary " DATA="5 "/>`
i have to align all the fields properly like this what to do help me.
`<userdata ID="11010014" PRI="1" Locator="Class_abc" DATA="5 "/>
<userdata ID="11010014" PRI="1" Locator="Class_abcde" DATA="5 "/>
<userdata ID="11010014" PRI="1" Locator="Class_ab" DATA="5 "/>`
ID length is constant
[1]: https://i.stack.imgur.com/v3Ff2.png
[2]: https://i.stack.imgur.com/W4RYP.png
Maybe this could be helpful
Step 1) search for:
h+(?!ID=|")
Replace with:
t
See the online demo
The pattern matches:
h+
- At least a single horizontal whitespace character.(?!ID=|")
- Negative lookahead for either literally 'ID=' or '"'.Step 2):
As soon as it's installed you'll notice it will auto-allign the tabs we just inserted.
Answered by JvdV on December 30, 2021
Get help from others!
Recent Questions
Recent Answers
© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP