I see what you mean - I use Redemption to scan all folders and extract
messages - For this I am creating a SafeMailItem, and feeding it an item
from Outlook (along the lines of $sItem->{Item} = $message; where $message
is a message item from a folder)
Here, I am not feeding MAPIUtils anything to bind to.
Ideally, what I want to do is trap all incoming and outgoing mail, so that
it can be scanned (it sounds a little like your client side spam filter). I
was looking at the NewMail event as it seems to pass the actual mail - Of
course it doesn't trap outbound, but I presume I need to use the Outlook's
own sent mail event to see this, and then identify the message
Can't work out what I am supposed to be giving MAPIUtils as an object,
though
Thoughts gratefully received.
Nigel
-----Original Message-----
From: Steven Manross [mailto:[EMAIL PROTECTED]
Sent: 02 February 2006 21:01
To: Nigel Cannings; [email protected]
Subject: RE: Redemption
> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] On
> Behalf Of Nigel Cannings
> Sent: Thursday, February 02, 2006 8:16 AM
> To: [email protected]
> Subject: Redemption
>
> I am trying to access the Redemption MAPIUtils NewMail event
> using Win32::OLE - I have been successful in using Redemption
> to perform a number of tasks, but I am stuck on this event
>
> The only interface I can find to bind to (using OLEVIEW) is
> IMAPIUtils.
> However, it generates no events. Anyone got any ideas (code
> below) - thanks nigel
>
>
How exactly are you using it and what are you intending to do with it? I
use Redemption on a regular basis (and had it working with Outlook to
create a client-side SPAM filter--SpamAssassin where I did not control
the Exchange Server--just my Outlook message box).
You've got the basics down pat.. But this code is far from complete..
$sItem needs to be passed an outlook object to bind to which you don't
show below.. Some more info would help (or is this everything?).
> use Win32::OLE qw(EVENTS);
>
> my $sItem = Win32::OLE->CreateObject("Redemption.MAPIUtils");
> Win32::OLE->WithEvents($sItem, \&Event, 'IMAPIUtils' );
>
> Win32::OLE->MessageLoop();
>
>
>
> sub Event {
> my ($Obj,$Event,@Args) = @_;
> print "Event triggered: '$Event'\n";
> }
>
>
> _______________________________________________
> Perl-Win32-Users mailing list
> [email protected]
> To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
>
>
_______________________________________________
Perl-Win32-Users mailing list
[email protected]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs