Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Perl > Perl Misc > Tranlating VB code into Perl to utilise Outlook Redemption

Reply
Thread Tools

Tranlating VB code into Perl to utilise Outlook Redemption

 
 
Graham
Guest
Posts: n/a
 
      03-18-2006
Outlook Redemption is a COM object that works around the security issues of
Outlook 2002+, and I wanna use this in a Perl script that works with Outlook
in sending email. My problem is that I don't know VB well enough to
translate the sample VB code for 'Send email bypassing the security prompt'
at the following address
http://www.dimastr.com/redemption/objects.htm#examples , into Perl.

Can anyone help?


 
Reply With Quote
 
 
 
 
Graham
Guest
Posts: n/a
 
      03-18-2006
Silly me..., the VB code in question is as follows:-

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 "(E-Mail Removed)"
SafeItem.Recipients.ResolveAll
SafeItem.Subject = "Testing Redemption"
SafeItem.Send


 
Reply With Quote
 
 
 
 
Matt Garrish
Guest
Posts: n/a
 
      03-18-2006

"Graham" <(E-Mail Removed)> wrote in message news:441c6009.0@entanet...
> Outlook Redemption is a COM object that works around the security issues
> of Outlook 2002+, and I wanna use this in a Perl script that works with
> Outlook in sending email. My problem is that I don't know VB well enough
> to translate the sample VB code for 'Send email bypassing the security
> prompt' at the following address
> http://www.dimastr.com/redemption/objects.htm#examples , into Perl.
>
> Can anyone help?


This should get you started: (untested, of course, as I don't have
Redemption)

use Win32::OLE;

my $Application = new Win32::OLE('Outlook.Application');

my $oItem = $Application->CreateItem(0);

my $SafeItem = new Win32::OLE('Redemption.SafeMailItem');

$SafeItem->{'Item'} = $oItem;


Translating the rest on your own shouldn't be too much to ask.

Matt


 
Reply With Quote
 
Graham
Guest
Posts: n/a
 
      03-18-2006
Aah - that looks more familiar. Thanks Matt!


"Matt Garrish" <(E-Mail Removed)> wrote in message
news:04_Sf.18038$(E-Mail Removed).. .
>
> "Graham" <(E-Mail Removed)> wrote in message news:441c6009.0@entanet...
>> Outlook Redemption is a COM object that works around the security issues
>> of Outlook 2002+, and I wanna use this in a Perl script that works with
>> Outlook in sending email. My problem is that I don't know VB well enough
>> to translate the sample VB code for 'Send email bypassing the security
>> prompt' at the following address
>> http://www.dimastr.com/redemption/objects.htm#examples , into Perl.
>>
>> Can anyone help?

>
> This should get you started: (untested, of course, as I don't have
> Redemption)
>
> use Win32::OLE;
>
> my $Application = new Win32::OLE('Outlook.Application');
>
> my $oItem = $Application->CreateItem(0);
>
> my $SafeItem = new Win32::OLE('Redemption.SafeMailItem');
>
> $SafeItem->{'Item'} = $oItem;
>
>
> Translating the rest on your own shouldn't be too much to ask.
>
> Matt
>



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Can we install IE onto a Mac so that it can utilise RWW? Alan NZ Computing 18 11-27-2008 06:34 AM
help tranlating perl expressions David Bear Python 4 09-28-2006 08:57 PM
DVD Verdict reviews: THE SHAWSHANK REDEMPTION: SPECIAL EDITION and more! DVD Verdict DVD Video 0 11-08-2004 10:12 AM
WWW:Shawshank Redemption SE (R1) Details Tom Woodward DVD Video 0 06-25-2004 10:34 AM
New Releases: Johnson Vacation, Redemption & Futurama: Updated complete downloadable R1 DVD DB & info lists Doug MacLean DVD Video 0 05-27-2004 04:42 AM



Advertisments