in reply to Re^3: Win32::OLE Excel AutoFill not working
in thread Win32::OLE Excel AutoFill not working
But when I change B17 to A17, it works as expected. Any idea why, given that you can select a single cell in Excel and auto-fill as many rows and columns as you like without failure.use Win32::OLE; use Win32::OLE::Const 'Microsoft Excel'; my $excel = Win32::OLE->CreateObject ('Excel.Application') or die $!; $excel->{Visible} = 1; my $workbook = $excel->Workbooks->Add; my $worksheet = $workbook->ActiveSheet; $worksheet->Range ('A1')->{Value} = 1; $worksheet->Range('A1')->AutoFill({ Destination => $worksheet->Range('A1:B17'), Type => xlFillDefault, });
|
|---|