M
marzec.wojciech
Hi,all
I have got small script like this below:
use Win32::OLE qw(in with);
use Win32::OLE::Const 'Microsoft Excel';
use Cwd;
$Win32::OLE::Warn = 3;
my $path = getcwd."/przyklad.xls";
$path =~ tr /\//\\/;
my $excel=Win32::OLE->new('Excel.Application','Quit');
my $book = $excel->Workbooks->Add;#
my $sheet = $book->Worksheets(1);
$book->Sheets->Add;
$book->SaveAs($path);
print $sheet->Name;
#$sheet->Name = "something";
undef $book;
$excel->Quit;
undef $excel;
...and i want to rename one of excel sheet, unfortunetly variable
$sheet->Name is only read-only and when i uncomment this line I will
receive message :
Can't modify non-lvalue subroutine call at excel_basic.pl
I will be grateful for any help.
Thank You
I have got small script like this below:
use Win32::OLE qw(in with);
use Win32::OLE::Const 'Microsoft Excel';
use Cwd;
$Win32::OLE::Warn = 3;
my $path = getcwd."/przyklad.xls";
$path =~ tr /\//\\/;
my $excel=Win32::OLE->new('Excel.Application','Quit');
my $book = $excel->Workbooks->Add;#
my $sheet = $book->Worksheets(1);
$book->Sheets->Add;
$book->SaveAs($path);
print $sheet->Name;
#$sheet->Name = "something";
undef $book;
$excel->Quit;
undef $excel;
...and i want to rename one of excel sheet, unfortunetly variable
$sheet->Name is only read-only and when i uncomment this line I will
receive message :
Can't modify non-lvalue subroutine call at excel_basic.pl
I will be grateful for any help.
Thank You