On Thu, 2 Oct 2003, Gerd Ewald wrote to TBUDL: >> I thought that %REGEXPTEXT captured the highest numbered subpattern, >> in this case 2, but it seems to be capturing subpattern 1.
> I'm quite sure it does. > Try this: ^subject:\s(?:\*\*\*\sGMX\sSpamverdacht\s\*\*\*\s)?(.*?)$ > This escapes the first parentheses and it does not count as a > subpattern Ah. Thanks. Looks like I should reread your tutorial in its entirety. >>And if I want to >> capture a subpattern other than 0 or 1 I will have to use >> %SETPATTREGEXP, %REGEXPBLINDMATCH, and %SUBPATT ? > Try > %SETPATTREGEXP="^subject:\s(\*\*\*\sGMX\sSpamverdacht\s\*\*\*\s)?(.*?)$"%- > %REGEXPBLINDMATCH="%HEADER"%- > %SUBPATT="2" I'm happy to see that what I put in after I sent my OP was what you recommend here. :) %SETPATTREGEXP="^subject:\s(\*\*\*\sGMX\sSpamverdacht\s\*\*\*\s)?(.*?)$"%- %REGEXPBLINDMATCH="%TEXT"%- %SUBPATT="2" > I hope the macro is %HEADER?? It's %TEXT. Hamster has already extracted the original headers, and they appear in the text body of the message that TB! has available to examine. > HTH It certainly did. Thank you! -- Mike TB! v1.62r Hamster Classic v1.3.23.4 Windows XP 5.1.2600 Service Pack 1 ________________________________________________ Current version is 2.00.6 | "Using TBUDL" information: http://www.silverstones.com/thebat/TBUDLInfo.html

