my $parser = Spreadsheet::ParseExcel::SaveParser->new(); my $template = $parser->Parse('test.xls'); my $line = 0; my $file = "color.txt"; tie my @array, 'Tie::File', $file or die "Cannot open $file: $!"; for my $worksheet ($template->worksheets() ) { my ( $row_min, $row_max ) = $worksheet->row_range(); my ( $col_min, $col_max ) = $worksheet->col_range(); for my $row ( $row_min .. $row_max ) { for my $col ( $col_min .. $col_max ) { $line++; my $cell = $worksheet->get_cell( $row, $col ); next unless $cell; my $format = $cell->get_format(); my $font = $format->{Font}; my $color = $font->{Color}; $array[$line] .= "\t $color"; } } } untie @array;