title: Get name of excel worksheets in perl
body: <p>I am a newbie to coding and perl.</p>
  
  <p>I am trying to read names of excel worksheets in an excel file through Perl</p>
  
  <p>Following is my code</p>
  
  <pre><code>#!/usr/local/ActivePerl-5.12/bin//perl -w
  
  use strict;
  use Spreadsheet::ParseExcel;
  
  my $FileName = "/Users/labuser/Desktop/TestAutomation/Results.xls";
  
  my $parser   = Spreadsheet::ParseExcel-&gt;new();
  my $workbook = $parser-&gt;parse($FileName);
  
  die $parser-&gt;error(), ".\n" if ( !defined $workbook );
  
  for my $worksheet ( $workbook-&gt;worksheets() ) {
  
  print $worksheet;
  
  }   
  </code></pre>
  
  <p>But i am not able to get name of the worksheet through print $worksheet.
  Please suggest how can i get that</p>