Hello bats, on Thu, 5. Feb 2004 at 23:49:12 +0100 Arjan de Groot wrote:
>>> %IF:"%TO"has"yahoogroups.com"in it:%FROM="Arjan de Groot <[EMAIL PROTECTED]>": >>> %FROM="Arjan de Groot <[EMAIL PROTECTED]>" >>%SETREGEXPPATT='.*?@(yahoogroups.com)'&- >>%IF:%REGEXPMATCH='%TO'<>'':%FROM="Arjan de Groot <[EMAIL PROTECTED]>":%- >>%FROM="Arjan de Groot <[EMAIL PROTECTED]>" A> I tried it, but alas, no success. :-( As Zygmunt wrote, it should be %SETPATTREGEXP instead of %SETREGEXPPAT, I didn't test it. Either you try this again or use the (modified) solution of Januk, but you should get your %IF-solution.. :) A> The %IF part in particular got me puzzled. What does it mean? A> "If <match> matches <To-field> doesn't match <blank>" IF <regular expression> matches THEN %FROM="Arjan de Groot <[EMAIL PROTECTED]>" ELSE %FROM="Arjan de Groot <[EMAIL PROTECTED]> ..and the regular expression checks for the pattern ",*?(yahoogroups.com)" (anything which ends with "@yahoogroups.com") in %TO.. you should probably include the THEN and ELSE parts of the %IF macro in ''s, from the beginning of : upto the end, like this: %SETREGEXPPATT='.*?@(yahoogroups.com)'&- %IF:%REGEXPMATCH='%TO'<>'':'%FROM="Arjan de Groot <[EMAIL PROTECTED]>"':%- '%FROM="Arjan de Groot <[EMAIL PROTECTED]>"' Don't know, if this is necessary, as this is try-and-see for myself. A> I'm feeling like I'm in 1st grade all over again. Don't have to. Check the help. it's not good, but can help though.. :) -- shinE! http://www.thequod.de ICQ#152282665 GnuPG/PGP key: http://thequod.de/danielhahler.asc Using The Bat! v2.03 Beta/53 on Windows XP 5.1 Build 2600 Service Pack 1 with POPFile 0.20.1 and avast Jan2004 (4.1.342) ________________________________________________________ http://www.silverstones.com/thebat/TBUDLInfo.html