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

I am wading into PowerPoint OLE. I lifted some code from an earlier thread to open an existing presentation like so:

use strict; use Win32::OLE qw(in with); use Win32::OLE::Const 'Microsoft PowerPoint'; my $app = Win32::OLE->new('PowerPoint.Application', 'Quit') || die "Ca +n't open powerpoint\n"; my $pres = $app->Presentations->Open({FileName=>'test.ppt', ReadOnly=> +1}) || print "Can't open presentation\n";

Trouble is, when I run this the open method sets $pres to "1" rather than a hash value. Also I leave PP open and it does not seem to actuall open test.ppt. Where am I going wrong?

Replies are listed 'Best First'.
Re: Powerpoint OLE problems
by sheep (Chaplain) on Jan 04, 2004 at 19:11 UTC
      Thanks that did it and I will check out the Roth book. Looks very useful.
Re: Powerpoint OLE problems
by poj (Abbot) on Jan 04, 2004 at 19:13 UTC
    my $app = Win32::OLE->new(... # add this line to see it open $app->{Visible}=1;
    poj