Group for strings

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
euras
Posts: 429
Joined: 05 Nov 2015, 12:56

Group for strings

12 Nov 2019, 09:37

is it possible to create something similar to GroupAdd, but not for Windows, NOT using arrays?
something like:

Code: Select all

GroupAdd, first_g, first
GroupAdd, first_g, second
GroupAdd, first_g, third
if (InStr(ahk_group first_g, "second"))
	Msgbox, found
else
	Msgbox not found
I may be faster way to perform the task, than for x,y in Array and easier to maintain it, just adding extra item to the group. Any ideas?
Rohwedder
Posts: 7645
Joined: 04 Jun 2014, 08:33
Location: Germany

Re: Group for strings

12 Nov 2019, 10:03

Hallo,
why not?:

Code: Select all

first_g .= "first"
first_g .= "second"
first_g .= "third"
if (InStr(first_g, "second"))
	Msgbox, found
else
	Msgbox not found

Return to “Ask for Help (v1)”

Who is online

Users browsing this forum: FanaticGuru, filipemb, LRRUNB and 195 guests