This pattern works like a charm in regex101
but not work with AutoHotkey, here is the code.
Code: Select all
while (re_pos := RegExMatch(Text, "O)(\t){0,}for k,v in ([^}]|\s)*+}", re_occur, (re_pos ? re_pos + 1 : 1)))
{
MsgBox % ": " re_occur[0]
}
Code: Select all
while (re_pos := RegExMatch(Text, "O)(\t){0,}for k,v in ([^}]|\s)*+}", re_occur, (re_pos ? re_pos + 1 : 1)))
{
MsgBox % ": " re_occur[0]
}
Code: Select all
while (re_pos := RegExMatch(Text, "Os)\t*for k,v in [^}]*}", re_occur, (re_pos ? re_pos + 1 : 1)))
{
MsgBox % ": " re_occur[0]
}
Thank you so much !just me wrote:You might need the s option for AHK:Code: Select all
while (re_pos := RegExMatch(Text, "Os)\t*for k,v in [^}]*}", re_occur, (re_pos ? re_pos + 1 : 1))) { MsgBox % ": " re_occur[0] }
Users browsing this forum: balawi28, Bing [Bot], Google [Bot], moltenchees and 260 guests