Hi, I am looking for a way to add a new recipient to the BCC list in order to send a copy to a Sharepoint mail account: This is the empty body of how to implement a standard application, but what do I need to do to add new recipient to the BCC list? The MSDN doesnt give me any clue on this and the references are not well documented with examples. What is the best way to program event sinks anyway as there is no IntelliSense support? ' Reference to ADO 2.5 and CDO for Microsoft Exchange Implements CDO.ISMTPOnArrival Private Sub ISMTPOnArrival_OnArrival( ByVal Msg As IMessage, pEventStatus as CdoEventStatus ) Msg.TextBody = Msg.TextBody & vbCrLf & "Text added by the sink." ' Commit the changes into the transport Stream Msg.DataSource.Save End Sub Thank you! Andreas Cieslik
The BCC field of a message is a envelope field or P1 message header you can modify the envelope message headers via the envelope fields see http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cdosys/html/88a535b0-7e41-4756-b04a-1699f0f14ea0.asp. One example of this is the catchall event sink http://support.microsoft.com/kb/324021. A word of warning tread carefully you can very easily create a message loop using poor code and logic if you modify the recipient list (my preferred method is to copy the message itself). If you want to write sinks in C# have a look at http://support.microsoft.com/kb/894286 Cheers Glen "Andreas Cieslik" wrote in message news:%239s7MvlYHHA.5044@TK2MSFTNGP05.phx.gbl... > Hi, > > I am looking for a way to add a new recipient to the BCC list in order to > send a copy to a Sharepoint mail account: > > This is the empty body of how to implement a standard application, but > what do I need to do to add new recipient to the BCC list? > > The MSDN doesnt give me any clue on this and the references are not well > documented with examples. > > What is the best way to program event sinks anyway as there is no > IntelliSense support? > > ' Reference to ADO 2.5 and CDO for Microsoft Exchange > Implements CDO.ISMTPOnArrival > > Private Sub ISMTPOnArrival_OnArrival( ByVal Msg As IMessage, pEventStatus > as CdoEventStatus ) > Msg.TextBody = Msg.TextBody & vbCrLf & "Text added by the sink." > ' Commit the changes into the transport Stream > Msg.DataSource.Save > End Sub > > > Thank you! > Andreas Cieslik >