minimum security for outlook security manager

Add-in Express™ Support Service
That's what is more important than anything else

minimum security for outlook security manager
minimum security for outlook security manager 
Daryl Shenner




Posts: 1
Joined: 2010-11-29
One of my clients gets an error when sending and I believe it is related to his security setup. I gave him a test app that was as simple as i could make it. When calling the ConnectTo method he gets "Method '~' of object '~' failed"

Do you have any suggestions for troubleshooting? Thanks

secman.dll 2.0.0.6
Private Sub Command1_Click()

Dim IOutlook As Object 'Outlook.Application
Dim OLSecurity As New OutlookSecurityManager
Dim IOutlookExpl As Object 'Outlook.Explorer
Dim IMail As Object 'Outlook.MailItem
Dim IRecipient As Object 'Outlook.Recipient

Set IOutlook = CreateObject("Outlook.Application")

Set IOutlookExpl = IOutlook.GetNamespace("MAPI").GetDefaultFolder(6).GetExplorer
Set IMail = IOutlook.CreateItem(0)

Call OLSecurity.ConnectTo(IOutlook)
OLSecurity.DisableOOMWarnings = True

Set IRecipient = IMail.Recipients.Add("abc@xyz.com")
IRecipient.Type = 1
IRecipient.Resolve
IMail.Subject = "Subject"
IMail.Body = "Body"
IMail.Send

OLSecurity.DisableOOMWarnings = False
IOutlookExpl.Close

SendOutlookMail = True

End Sub
Posted 29 Nov, 2010 13:58:46 Top
Andrei Smolin


Add-in Express team


Posts: 14111
Joined: 2006-05-11
Hi Daryl,

Is Outlook installed on that system? Or, if something is wrong with Outlook, you should get the issue on the IOutlook.GetNamespace("MAPI").GetDefaultFolder(6).GetExplorer line.

Is that code run in a standalone application?

Is the issue reproducible if you turn off all COM add-ins? To turn a COM add-in off, set LoadBehavior = 0 in {HKLM and HKCU}\Software\Microsoft\Office\Outlook\Addins\{an add-in}.

Regards from Belarus (GMT+2),

Andrei Smolin
Add-in Express Team Leader
Posted 30 Nov, 2010 09:37:53 Top