View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
JP[_7_] JP[_7_] is offline
external usenet poster
 
Posts: 8
Default Prevent dialog - Prevents Sending Excel File From Outlook

Hi,

I've read that:

"Outlook prevents e-mail messages from being sent
programmatically from
Outlook without your knowledge by displaying a dialog that
enables you to send or not
send the message."

I want to disable this protection...


I have attempted to install outlook redemption from:

http://www.dimastr.com/redemption


I installed the file and now it is in

C:\Program Files\Redemption\Redemption.dll


Then I have gone to excel and:

1: Go to the VBA editor, Alt -F11
2: ToolsReferences in the Menu bar
3: Place a Checkmark before Microsoft Office Outlook 9.0
Object Library


Then I have put in the following code:

Sub safe_send_mail

dim SafeItem, oItem
set SafeItem = CreateObject
("Redemption.SafeMailItem") 'Create an instance of
Redemption.SafeMailItem
set oItem = Application.CreateItem(0) 'Create a new message
SafeItem.Item = oItem 'set Item property
SafeItem.Recipients.Add "
SafeItem.Recipients.ResolveAll
SafeItem.Subject = "Testing Redemption"
SafeItem.Send

End Sub


But I get the following error;

Object doesn't support this property or method (Error 438)


Please tell me what I am doing wrong! Any suggestions
would be great.

Thanks.