AHK V2: match object: backreference name as key? Topic is solved
AHK V2: match object: backreference name as key?
Is there a way to get match object keys to be the backreference names instead of backreference numbers, or is that a feature request?
Re: AHK V2: match object: backreference name as key? Topic is solved
I had an AHK v1 example here, which I've converted to AHK v2:
jeeswg's RegEx tutorial (RegExMatch, RegExReplace) - AutoHotkey Community
https://autohotkey.com/boards/viewtopic.php?f=7&t=28031Is that what you want?
jeeswg's RegEx tutorial (RegExMatch, RegExReplace) - AutoHotkey Community
https://autohotkey.com/boards/viewtopic.php?f=7&t=28031
Code: Select all
q::
RegExMatch(A_Now, "^(?P<Year>\d{4})(?P<Month>\d{2})(?P<Day>\d{2})", oMatch)
MsgBox(oMatch.Year " " oMatch.Month " " oMatch.Day)
return
homepage | tutorials | wish list | fun threads | donate
WARNING: copy your posts/messages before hitting Submit as you may lose them due to CAPTCHA
WARNING: copy your posts/messages before hitting Submit as you may lose them due to CAPTCHA
Re: AHK V2: match object: backreference name as key?
Thanks for that!