http://www.perlmonks.org?node_id=1008376


in reply to Re: Using Win32::OLE and Excel - Tips and Tricks
in thread Using Win32::OLE and Excel - Tips and Tricks

This piece of code doesn't work because "Selection" is a method of the parent Excel application, not the sheet.

So if you had, in the beginning of your code:

my $XcelApp = Win32::OLE->new( 'Excel.Application' );

Then the second line in your post should go:

$XcelApp->Selection->Copy('A17');

Helen