in reply to Copy paste rows in excel
Well, i wrote the following and it worked on my system.
as one would work manually with excel (step by step), that helps with perl/excel.
That's my feeling anyway!
With what I've learnt using excel<->perl, i've found that one should write the codeuse Win32::OLE; my $excelfile = 'E:\\perl scripts\\abc.xls'; my $Excel = Win32::OLE->GetActiveObject('Excel.Application') || Win32::OLE->new('Excel.Application', 'Quit'); $Excel->{'Visible'} = 1; my $Book = $Excel->Workbooks->Open($excelfile); my $Sheet = $Book->Worksheets("Sheet1"); $Sheet->Activate(); #------Here's what u were looking for $Sheet->range('A4')->copy(); $Sheet->range('B1')->Select(); $Sheet->paste();
as one would work manually with excel (step by step), that helps with perl/excel.
That's my feeling anyway!
Raghu
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^2: Copy paste rows in excel
by Ankit.11nov (Acolyte) on Jul 21, 2009 at 08:19 UTC | |
by imrags (Monk) on Jul 21, 2009 at 09:06 UTC | |
by Anonymous Monk on Dec 29, 2016 at 13:45 UTC | |
by Corion (Patriarch) on Dec 29, 2016 at 14:00 UTC | |
by davies (Prior) on Dec 29, 2016 at 23:41 UTC | |
by Ankit.11nov (Acolyte) on Jul 21, 2009 at 09:36 UTC |
In Section
Seekers of Perl Wisdom