v705Cas has asked for the wisdom of the Perl Monks concerning the following question:

Hi all,

For my sins, I run a legacy 5.24 install on which I have built an app of 15 years standing. Recently I have discovered that my Microsoft Outlook integration needed to send scheduled emails breaks on Windows boxes with 64 bit Office installs, while it runs fine with 32 bit Office installs.

The exact error thrown is:

No type library matching "Microsoft Outlook" found at ../Perl/lib/Mail +/Outlook.pm line 111

While there do appear to be plenty of people who've encountered this issue, I do have some constraints which is why their solutions might not apply to my situation. First, I am unfortunately not open to upgrading my installation. Given enough time, I'd love to do that but there's never enough time, especially when there are tight deadlines! Second, I do not have the ability to directly manually tinker with the Registry settings on the machines this application must run on, as local admin rights are locked down.

I'm definitely not afraid though of tinkering with the modules. There are no external dependencies I have to satisfy so it is my private playground to hack around as I like with.

Question: How would I go about finding the exact changes needed at the Module level (or even as calls in my code) to address this issue? I've taken a good look around the Meta CPAN site but am none the wiser (all I can see is file permission and version bumps). I still want the application to run with 32 bit Office installs as well as 64 bit Office installs.

Many thanks in advance!

Andrew

Replies are listed 'Best First'.
Re: Integration with 64 Bit Office installs
by Corion (Patriarch) on Mar 21, 2025 at 15:53 UTC

    Only 64bit applications can talk to 64bit OLE / COM.

    You will need to upgrade your Perl to a 64bit Perl. You will likely need to download and install all modules required by your application(s) again.

    Strawberry Perl offers a 64bit 5.24, for example.

    I recommend first trying a 5.38 or 5.40 version of Perl, since there was very little in terms of breaking changes in-between.

      Hi there, thanks for the suggestion, but as stated, this is not an option as this would require a lot of time. Just looking for a quick fix to get the Outlook.pm functional with 64 bit installs

        Not going to happen. The issue is with Win32::OLE compiled against a 32 bit perl, it won't have access to 64bit COM objects. You can't just package your app, provide a 32 & 64 bit version?

Re: Integration with 64 Bit Office installs
by choroba (Cardinal) on Mar 24, 2025 at 19:49 UTC
    Crossposted to StackOverflow. It's OK to crosspost, but it's considered polite to inform about crossposting to prevent people not attending both sites from spending time on a solution of a problem already solved at the other end of the internets.

    map{substr$_->[0],$_->[1]||0,1}[\*||{},3],[[]],[ref qr-1,-,-1],[{}],[sub{}^*ARGV,3]