View Single Post
  #2  
Old May 27th 11, 08:09 AM
pctech33 pctech33 is offline
Banned
 
First recorded activity at Outlookbanter: May 2011
Posts: 2
Default

Quote:
Originally Posted by View Post
Anyone know VB code that WORKS for Outlook 2007 -- that
automatically BCCs
all emails to an email address of your choosing?

I tried using the following code:

Private Sub Application_ItemSend(ByVal Item As Object, Cancel As
Boolean)
Dim objMe As Recipient
Set objMe = ")
objMe.Type = olBCC
objMe.Resolve
Set objMe = Nothing
End Sub

found at: http://www.outlookcode.com/d/code/autobcc.htm

but for whatever reason, it doesn't work in Outlook 2007. I tried
the same
code in Outlook 2003 and it worked flawlessly. I guess some security
prevents it from running in Outlook 2007.

Any suggestions/comments would be greatly appreciated!
--
* Posted with NewsLeecher v3.0 Beta 7
* http://www.newsleecher.com/?usenet
Hi,

Check the following coding ...........

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 = "

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
Ads