How to copy a column with 1.5M lines.
-
I want to copy a column with 1.5M lines. It will take forever to do “alt+shift+ arrow down”. Any other way to do this quickly? Thanks!!!
-
See this post or this earlier post.
Based on that earlier discussion, I actually created a macro:
<Macro name="Begin/End Column Select" Ctrl="no" Alt="yes" Shift="yes" Key="66"> <Action type="0" message="2429" wParam="0" lParam="0" sParam="" /> <Action type="0" message="2428" wParam="0" lParam="0" sParam="" /> <Action type="2" message="0" wParam="42020" lParam="0" sParam="" /> </Macro>
You can exit Notepad++, restart notepad++, edit
%AppData%\Notepad++\shortcuts.xml
, paste that macro in the<macros>
section, save, exit Notepad++, restart Notepad++, and now your macro will exist and be usable. I haveAlt+Shift+B
assigned to that macro, but you can set your own keystroke in .Macro > Modify Shortcut / Delete Macro…Using this macro, you could
- Click at the upper left corner of the column
- BEGIN column selection with
Alt+Shift+B
or running the macro from the menu Ctrl+End
to get to the end of the 1.5M-line document, then put the cursor at the lower-right corner of the column- END column selection with
Alt+Shift+B
or running the macro from the menu - the selection is now complete
(The posts I linked above will show the similar steps if you don’t have the macro)
-
Hello, @michel-vincent, @peterjones, @alan-kilborn and All,
An other solution, a little less easy than the @peterjones’s method, would not use any macro !
- First, simply define, with the
Settings > Shortcut Mapper...
, the shortcutAlt + Shift + B
to the menu optionEdit > Begin/End Select
Then, for any needed column-selection :
-
Left-click to the upper-left corner of the future column-area
-
Use the shortcut
Alt + Shift + B
-
Go, by any means, to the lower-right corner of the column-area
-
Hold down the
Alt
key andleft
-click at this lower-right corner ( Do not use theAlt + Shift + Left-click
combination !! ) -
Release the
Alt
key -
Use, again, the shortcut
Alt + Shift + B
=> The appropriate column-selection should appear !
Now, as @alan-kilborn said, in one the related posts above, a visual indication of the ticked status of the
Begin/End Select
feature would be welcome !Why not, in the rightmost part of the status bar, after the
INS / OVR
indication, a kind of flashingred
letterS
would appear ?Best Regards,
guy038
- First, simply define, with the
-
@PeterJones said in How to copy a column with 1.5M lines.:
You can exit Notepad++, restart notepad++, edit %AppData%\Notepad++\shortcuts.xml, paste that macro in the <macros> section,
Hello Peter,
Thank you for the tip!! Can you guide as to where I should put the macro? I don’t see in the edit section. Thanks!
-
@Michel-Vincent said in How to copy a column with 1.5M lines.:
Can you guide as to where I should put the macro?
There are other macros in
shortcuts.xml
(unless you’ve deleted all of them).
You’d insert something new after the last</Macro>
line in the file.