Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #31  
Old 05-25-2012, 07:55 AM
XopieX20 XopieX20 is offline Outlook: automatic BCC to another e-mail account for all sent messages Windows 7 64bit Outlook: automatic BCC to another e-mail account for all sent messages Office 2007
Novice
 
Join Date: May 2012
Location: Indiana
Posts: 9
XopieX20 is on a distinguished road
Default

Just to let everyone know I have solved this auto BCC issue. This is the code you need to use to auto BCC AND if you are using more than 1 box. If not, just use the IF code 1 time.



Private Sub Application_ItemSend(ByVal Item As Object, _
Cancel As Boolean)
Dim objRecip As Recipient
Dim strMsg As String
Dim res As Integer
Dim strBcc As String
On Error Resume Next


If Item.SentOnBehalfOfName = "THIS MUST BE THE DISPLAY NAME OF THE EMAIL" Then
strBcc = "BCC Email Goes Here"
End If

If Item.SentOnBehalfOfName = "THIS MUST BE THE DISPLAY NAME OF THE EMAIL" Then
strBcc = "BCC Email Goes Here"
End If

If Item.SentOnBehalfOfName = "THIS MUST BE THE DISPLAY NAME OF THE EMAIL" Then
strBcc = "BCC Email Goes Here"
End If

If Item.SentOnBehalfOfName = "THIS MUST BE THE DISPLAY NAME OF THE EMAIL" Then
strBcc = "BCC Email Goes Here"
End If

If Item.SentOnBehalfOfName = "THIS MUST BE THE DISPLAY NAME OF THE EMAIL" Then
strBcc = "BCC Email Goes Here"
End If

If Item.SentOnBehalfOfName = "THIS MUST BE THE DISPLAY NAME OF THE EMAIL" Then
strBcc = "BCC Email Goes Here"
End If



Set objRecip = Item.Recipients.Add(strBcc)
objRecip.Type = olBCC
If Not objRecip.Resolve Then
If res = vbNo Then
Cancel = True
End If
End If
Set objRecip = Nothing
End Sub
Reply With Quote
Reply



Similar Threads
Thread Thread Starter Forum Replies Last Post
Outlook: automatic BCC to another e-mail account for all sent messages Having a Problem synching outlook to my google account Sneefus Outlook 1 08-20-2010 02:43 PM
Outlook Deleted Messages NS1981 Outlook 2 07-19-2010 06:25 AM
Sending Outlook account to gmail ? bwall Outlook 0 09-24-2006 07:24 PM
Outlook: automatic BCC to another e-mail account for all sent messages Remove Exchange Server E-Mail account from Outlook Chance Outlook 3 04-07-2006 07:06 AM
Outlook Error Messages cindyb214 Office 2 11-23-2005 06:13 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 02:41 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft