Pages: 1
RSS
Macro to split email addresses?
 
Is their functionality available in The Bat! macros to split the first and last parts of the email address; eg split examplename@domainname.com into two strings, examplename and domainname.com?

Thank you,

Jeff Kogler
 
It's not available with macros, but a little regular expression would do just fine. Here's an example that does what you want:

%SetPattRegExp=_(.*)@(.*)_%-
%RegExpBlindMatch=_%ToAddr_%-
%SubPatt=_2_

I copied this from one of my own templates, where it's used to extract the domain. I'm using an underscore (_) in stead of single or double quotes, because it was originally part of a more complex structure where the quotes were used on another level, but that doesn't matter in how you use it.
In case you'd need the user part, you'd need %SubPatt=_1_

__________________________________
I'm just a user of The Bat! I don't work for Ritlabs.
 
Thanks, Roelof.  I shall investigate this further.

Jeff
Pages: 1