way to print a string of variable in notepad

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
Parama
Posts: 40
Joined: 27 Sep 2017, 22:38

way to print a string of variable in notepad

25 Oct 2017, 19:53

for example

variable :="abcde12345"

The string actually used is longer than it

How do I print this in Notepad?
User avatar
jeeswg
Posts: 6902
Joined: 19 Dec 2016, 01:58
Location: UK

Re: way to print a string of variable in notepad

25 Oct 2017, 20:06

Probably one of these two:

Code: Select all

;set text of whole Edit control
ControlSetText, Edit1, % vText, A

;insert text at caret point
Control, EditPaste, % vText, Edit1, A
homepage | tutorials | wish list | fun threads | donate
WARNING: copy your posts/messages before hitting Submit as you may lose them due to CAPTCHA
Parama
Posts: 40
Joined: 27 Sep 2017, 22:38

Re: way to print a string of variable in notepad

26 Oct 2017, 00:30

hmm.....Neither of them is running :roll:
User avatar
jeeswg
Posts: 6902
Joined: 19 Dec 2016, 01:58
Location: UK

Re: way to print a string of variable in notepad

26 Oct 2017, 00:36

Does this work?

Code: Select all

q::
vText := "abcde12345"
ControlSetText, Edit1, % vText, ahk_class Notepad
;Control, EditPaste, % vText, Edit1, ahk_class Notepad
return
homepage | tutorials | wish list | fun threads | donate
WARNING: copy your posts/messages before hitting Submit as you may lose them due to CAPTCHA
Jill Zanfer

Re: way to print a string of variable in notepad

26 Oct 2017, 03:45

what about this

somethingt := "hello world hello aloha"
send, %somethingt%

Return to “Ask for Help (v1)”

Who is online

Users browsing this forum: Google [Bot], NinjoOnline and 227 guests