in reply to Re: Error in Win32::OLE
in thread Error in Win32::OLE

MS Excel is installed in the PC. I was using the older version at that time

Now, I am using Microsoft 365. Is this impacting the perl script?

Replies are listed 'Best First'.
Re^3: Error in Win32::OLE
by Corion (Patriarch) on Oct 21, 2021 at 11:29 UTC

    Maybe Office 365 does not have OLE automation anymore - this seems plausible if Office 365 only runs within the browser, for example.

    Maybe look on your PC whether the type library file is findable and give that to Win32::OLE::Const explicitly.

    The alternative approach if all this fails is to replace all the named constants with their values, which you can acquire from Googling them.

Re^3: Error in Win32::OLE
by Bod (Parson) on Oct 21, 2021 at 20:44 UTC

    The latest application versions of Office 365 include OLE blocking. I have no idea if it is turned on by default - I can check sometime as it would be interesting to find out and potentially helpful to you. Here is some information from Microsoft.

    I am pretty certain that the cloud versions of Office 365 do not support OLE. Instead they use the Fluid Framework.