Login
     
  Latest Entries  
  Blog  
23

By using the built-in rules in Outlook you can automatically CC an email address on outgoing messages (and even specify additional criteria like key words in subject lines, etc.), but there is no option to use BCC. This article will show how to modify Outlook to automatically BCC an email address on all outgoing messages.

There are probably several reasons in which you would want to automatically BCC and email address on all outgoing messages (archival purposes being one of them). In this instance, I needed a solution to perform an automatic BCC to a system email address for a pilot of the Trampoline Systems SONAR product. SONAR can consume your daily email traffic and use it to create connections to people and topics (sort of like an automatic FaceBook application. After some hunting around the internets, I happened upon this solution, which I'll explain further here.

Note: This method was tested on Outlook 2007, but should work on Outlook 2003 or later.

  • In Outlook, go to the Tools menu, Macro option, and select Visual Basic Editor.
  • In the Project listing (upper left box on the screen), expand Project1 (VbaProject.OTM) and within that expand Microsoft Office Outlook Objects.
  • Double-click the ThisOutlookSession project to open it. In most cases this is empty, unless you've already been modifying your copy of Outlook with macros and such.
  • In the code window that opens up, choose Application from the left most drop-down list box, and ItemSend from the other (it might automatically be selected for you).
  • You should be presented with something like this:
  • Copy and paste the following code after the Private Sub line and before the End Sub line:
    Visual Basic
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    
        Dim objRecip As Recipient
        Dim strMsg As String
        Dim res As Integer
        Dim strBcc As String
        On Error Resume Next
    
        ' #### USER OPTIONS ####
        ' address for Bcc -- must be SMTP address or resolvable
        ' to a name in the address book
        strBcc = "SomeEmailAddress@domain.com"
    
        Set objRecip = Item.Recipients.Add(strBcc)
        objRecip.Type = olBCC
        If Not objRecip.Resolve Then
            strMsg = "Could not resolve the Bcc recipient. " & _
                     "Do you want still to send the message?"
            res = MsgBox(strMsg, vbYesNo + vbDefaultButton1, _
                    "Could Not Resolve Bcc Recipient")
            If res = vbNo Then
                Cancel = True
            End If
        End If
    
        Set objRecip = Nothing
    
    Note: Be sure to replace SomeEmailAddress@domain.com with your intended email address. To test your changes you may wish to temporarily it to a secondary email address (like a Gmail account), to make sure all is working correctly.
  • When you are done, it should look like this:

    You'll note that I have the intended email address set to the system account necessary for the SONAR product.
  • Save the VbaProject.OTM file, close the Visual Basic editor, return to Outlook, and start sending messages.

This should work for new messages as well as replies and forwarded messages. If you have any questions or comments, please comment on them here.

Posted in: Windows

Post Rating

Comments

There are currently no comments, be the first to post one.

Post Comment

Name (required)

Email (required)

Website

  Archives