info.mailtraq.com > Management > Script Functions A-Z > MsgSetRcpts() MsgSetRcpts()Replaces the recipient(s) of the current message envelope a supplied list of recipient(s), given as a comma separated string.
MsgSetRcpts( rcptlist )
- rcptlist
- A comma separated list of recipient(s)
Add two recipients to a message MsgSetRcpts(MsgGetRcpts() ++ "," ++
"fred@example.com, bill@example.com")
Notes
Comma separated lists with elements surrounded by quote marks, e.g. "address_one","address_two", are not recognised by this function therefore lists in the standard Mailtraq list format, "address_one,address_two" must be used.
This function operates prior to and in the inbound router in Mailtraq only. That is, the recipients of a message can be modified in a script triggered on Inbound Mail Delivery or on Mail Routing but not on Outbound Mail Delivery, because the message recipients are fixed by that stage in the routing process. |