$right = $workbook->add_format( size => 9, align => 'right', ); $table->write_number( $row, $col++, ($fields[0]+0), $right )