As we can instantly duplicate the current line in Scite and AHK Studio with the help me shortcut keys like ctrl+D and f2 respectively, I want any similar way to duplicate the current line for MS Word and notepad. Presently, I have mapped the default keys to duplicate the current line. Please see these codes-
Code: Select all
send {Home} ; brings the cursor to the starting of the line
Sleep 100
send +{End} ; selects the entire line
Sleep 100
send ^c ; copies the text
Sleep 100
send {down} ; goes to the next line
Sleep 100
send ^v ; pastes the text at next line
However, the above codes are working fine, but I want more professional way to do that. Like in scite it provides the facility to duplicate the current line by shortcut key ctrl+d and in AHK studio it has built in shortcut key f2.
Please tell me how to do this in MS Word and in Notepad?
Thanks a lot...