Pasting a string in three parts.

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
kaosgamerx7

Pasting a string in three parts.

21 Dec 2017, 08:49

Hello. I am new to AHK and have very basic undestanding of programming languages.

I want to paste a string of 12 Characters that will be stored in Clipboard in three different parts.

E.g. If string is 111122223333

Than I want it to first paste 1111 followed by a Tab 2222 Tab Again and finally 3333. All this by pressing only a single hotkey.

Is there anyway to do this ?

Thank you in Advance.
User avatar
Blackholyman
Posts: 1293
Joined: 29 Sep 2013, 22:57
Location: Denmark
Contact:

Re: Pasting a string in three parts.

21 Dec 2017, 09:01

one of meny ways

Code: Select all

f2::
string := Clipboard
Loop, parse, string
{
	send %A_LoopField%
	if !mod(A_index, 4)
		send %A_tab%
}
return
Also check out:
Courses on AutoHotkey

My Autohotkey Blog
:dance:
kaosgamerx7

Re: Pasting a string in three parts.

21 Dec 2017, 22:40

Thank You very much. Will try it today and let you know. Much appreciated.
kaosgamerx7

Re: Pasting a string in three parts.

22 Dec 2017, 01:04

Thank You. It did what I asked for. But at the end when the final string has been pasted, it sends two extra TAB press. Any way to avoid that ?

Return to “Ask for Help (v1)”

Who is online

Users browsing this forum: Google [Bot], newbieforever and 62 guests