Hello,
I'm trying to use a simple vbscript to send an e-mail via outlook 2003. To get around the pop-up security warning message I'm using the "Redemption" COM library.
For a few days my code seemed to work - but now I get the following error message: Could not submit the message - error 0x80004005, Source: Redemption.SafeMailItem.
The message correctly appears in Outlook's 'drafts' folder - but does not get sent. Could this be because Redemption has not be registered properly?
Can anyone help? My short script is as follows:
The error appears to occur on the line highlighted in [red]red[/red].
Many thanks
Andrew
I'm trying to use a simple vbscript to send an e-mail via outlook 2003. To get around the pop-up security warning message I'm using the "Redemption" COM library.
For a few days my code seemed to work - but now I get the following error message: Could not submit the message - error 0x80004005, Source: Redemption.SafeMailItem.
The message correctly appears in Outlook's 'drafts' folder - but does not get sent. Could this be because Redemption has not be registered properly?
Can anyone help? My short script is as follows:
Code:
set Application = CreateObject("Outlook.Application")
set Namespace = Application.GetNamespace("MAPI")
Namespace.Logon
dim SafeItem, oItem
set SafeItem = CreateObject("Redemption.SafeMailItem")
set oItem = Application.CreateItem(0)
SafeItem.Item = oItem
SafeItem.to = "someone@somewhere.com"
SafeItem.Subject = "Testing Redemption"
SafeItem.Body = "Hello World"
[red]SafeItem.Send[/red]
set Utils = CreateObject("Redemption.MAPIUtils")
Utils.Cleanup
The error appears to occur on the line highlighted in [red]red[/red].
Many thanks
Andrew