You are not logged in.
Can the motmor.net.client.SendEmail function be used to cc and bcc recipients, or is it only for to? I tried custom headers, but since the command is not sent for the cc and bcc addresses, only for to, it is never delivered to them.
Offline
Normally you would need to do a RCPT TO for each TO, CC and BCC.
To, Cc and Bcc headers can be used but will not be parsed by a mailserver if you do MAIL FROM and RCPT TO.
So you would need to add all the recipients to the CsvDest of the SendEMail call (so for all, the RCPT TO is done).
BCC in headers will normally be dropped.
The problem however... is that Mormot2 seems to just add all the CsvDest recipients to the To: line (resulting in double address in To and Cc and visible Bcc address in the TO).
You could remove this part, and make sure you add the To: (together with Cc: and Bcc:) yourself in the headers.
if {%H-}ToList = '' then
Join([#13#10'To: ', rec], ToList)
else
Append(ToList, ', ', rec);Or adjust this piece of code to check if address is already in BCC or CC header and NOT add it to the To: in these lines (which would be the best option).
Or have the opportunity to pass CC or BCC in the CsvDest (i.e. mymail@domain.com, CC: myothermail@domain.com, BCC: mysecretmail@domain.com).
Offline