Page 1 of 1

Line and its value

Posted: Thu Jan 26, 2023 8:12 pm
by JasonGH
I have many text files with so many lines that I want to line up lines with its value. For example:

Line1
Line2
Line3
...
...
...
Linex
ValueofLine1
ValueofLine2
...
...
...
...
ValueofLinex

To become:

Line1 ValueofLine1
Line2 ValueofLine2
...
...
Linex ValueofLinex

How can I do it with Marco or RE?

Thanks in advance

Posted: Thu Jan 26, 2023 8:26 pm
by AmigoJack
Activate Configure > Block Select Mode.

Now you can select text vertically instead of only by lines. That way you can select all your lines of values (in the picture lines 109 to 115), then cut them, and then paste them after a few spaces of your first line (in the picture line 100) to have all previously selected lines appended to the existing ones at that place:

Image

Posted: Sun Jan 29, 2023 5:10 am
by JasonGH
Thank you for your reply.

This one is totally manual work. I want to do with Macro and RE since we have thousands of text files with different line counts from 10 to 1000+ lines each.

All I want to do is: Open a text file - Run Macro - DONE.

Best,

Posted: Sun Jan 29, 2023 5:43 pm
by ben_josephs
How do you determine how many lines there are in the keys (first) section and the values (second) section? Can it be arranged that they are separated by an empty line?
How do you determine the maximum length of the lines in the keys section?