Aside from the original question (which I think has been answered quite well) I have a question for you. What happens if your Excel application isn't running? Then the Perl script wouldn't be able to GetActiveObject at all. I'd suggest the following addition:
my $excel = Win32::OLE->GetActiveObject('Excel.Application') or Win32::OLE->new('Excel.Application');And of course, check the return code to make sure things went smoothly. But that goes without saying, right? :)
In reply to Re: Class names in OLE
by Nkuvu
in thread Class names in OLE
by Foggy Bottoms
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |