Problems with SendObject and Outlook

  • Thread starter Thread starter John Lane
  • Start date Start date
J

John Lane

I’ve run into an Access/Outlook 2002 problem, and it
happens using both SendObject and the Outlook MAPI
interface. Outlook now throws up a message box saying that
a user is accessing the address book (I’m not) to send
email and do I (the user) say it is OK, and the user has
to click Yes/No. I suspect the famed Outlook security
patch is causing this. Is there a way to disable this
message and send silently? Thanks.
 
Also answered in "modulesdaovba:

What you are seeing is the Outlook Security Prompt, which is designed to
inhibit the proliferation of email viruses. If you are working in an
Exchange Server environment, there is a toolkit/patch available to control
the appearance of the Outlook Security Prompt:

http://www.slipstick.com/outlook/esecup/admin.htm

Otherwise, you'll find an extensive review of all of the options available
to work around the Outlook Security Prompt at:

http://www.slipstick.com/outlook/esecup.htm#autosec

The easiest work-around that I have found is to install the free ClickYes
utility found at:

http://www.express-soft.com/mailmate/clickyes.html

This utility can be incorporated into VBA code and will automatically click
the 'Yes' button of the security prompt. The writers of this software have
included code at their website which shows you how to turn the Utility on
and off from within your code. I have used this in more than one client
application and the most frequent problem I've seen is convincing users to
"keep their hands off the mouse".

hth,
 
Cheryl,

I have an app where I need to simultaneously send about 30 emails to
different recipients. I was able to successfully use the ClickYes utility,
but I thought I would pass on a problem I encountered, and the method I used
to solve it. Apparently, when you send multiple emails in a loop things are
moving so fast that Outlook does not have time to recover in between loops -
I kept getting CDO error 1005 on a random basis as it progressed through the
loop. I eventually built a delay between emails into the loop to prevent
this using the following code:

' build in a delay to avoid CDO error 1005
For intI = 1 To 50000 ' Start loop.
If intI Mod 100 = 0 Then ' If loop has repeated
' 100 times.
DoEvents ' Yield to operating
' system.
End If
Next intI

Bill
 
I haven't seen that problem myself, Bill, but I do appreciate your
mentioning it. Is it possible that this could be related to Windows or
Office versions? I'm using Win XP Pro and Office XP.
 
Back
Top