Hallo Christopher,

On Fri, 23 Jul 2004 08:57:51 -0700GMT (23-7-2004, 17:57 +0200, where I
live), you wrote:

>> Just insert the macro as it is here, with all
>> spaces and on as many lines as this example. It
>> should work though I didn't test it.

CB> I'm having a bit of trouble with the macro you offered. 

Yeah, notice the "should work" an "didn't test"

Try this one, it works I tested it. Still works for one recipient
only:

%If:$%ABToEmail$=$$:$$:$%-
%_To='"%-
%If:_%ABToNamePrefix_<>__:_%ABToNamePrefix _:__%-
%If:_%ABToFirstName_<>__:_%ABToFirstName _:__%-
%If:_%ABToMiddleName_<>__:_%ABToMiddleName _:__%-
%If:_%ABToLastName_<>__:_%ABToLastName_:__%-
%If:_%ABToNameSuffix_<>__:_ %ABToNameSuffix_:__%-
" <%ABToEmail>'%-
%To=""%To="%_To"$%-

This is what went wrong:

CB> %To=""%-

So here I'm emptying the to-header, since I 'd like to insert
something new and that's the biggest mistake, after all I try to get
the address info from the now empty to-header, so all my fields are
turning up empty.

CB> %If:_%ABToFirstName_<>__"_%ABToFirstName _:__%-
                            ^
And that quote mark should've been a colon
Furthermore there's this minor point that I called the suffix
%ABToSuffix instead of %ABToNameSuffix (and likewise for the prefix)

As I said, this will only work for messages with one recipient, but
since it deletes the old to-header that means that your template
refuses to accept multiple recipients in your to-header (except when
the first recipient isn't in your AB), so multiple recipients should
be included in either the cc- or bcc-fields.
Of course you could use an additional if-statement that tests for
multiple addresses.

-- 
Groetjes, Roelof

Disclaimer: Any opinion stated in this message is not necessarily shared by my budgies 
or rabbits.


________________________________________________
Current version is 2.12.00 | 'Using TBUDL' information:
http://www.silverstones.com/thebat/TBUDLInfo.html

Reply via email to