Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Re^4: Doubt regarding parsing

by pavanpvss (Novice)
on Apr 04, 2012 at 19:10 UTC ( #963513=note: print w/replies, xml ) Need Help??


in reply to Re^3: Doubt regarding parsing
in thread Doubt regarding parsing

use Spreadsheet::ParseExcel; my $filename = shift || 'C:\Earthlink.xls'; my $parser = Spreadsheet::ParseExcel->new(); my $workbook = $parser->parse($filename); if ( !defined $workbook ) { die $parser->error(), ".\n"; }

I have done exactly as you have told. But still i find the error "File Not found" . I have cross checked whether i have put the file in C:\ or not. I have done that. Can you please help me out. Thanks in advance

Replies are listed 'Best First'.
Re^5: Doubt regarding parsing
by ww (Bishop) on Apr 04, 2012 at 20:22 UTC
    No, you have not done "exactly" as toolic suggested. You're showing us single quotes around the file name. c.f. his line 3 at his first reply. See also any of the standard references re "interpolation."
Re^5: Doubt regarding parsing
by jandrew (Chaplain) on Apr 04, 2012 at 19:39 UTC

    pavanpvss sometimes you are not in the directory that you thought you were in. Try adding the following line to your code and run it before the 'my $filename' line.

    map { print $_ . "\n" } <C:\*>;

    Then check the output for your file. (note the similarities of the C:\ to your filename call).

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://963513]
help
Chatterbox?
[Discipulus]: [OT] if i have an svg image (a map of italian provinces) like this one in which way i need to interact with it to have a geochart?
[Corion]: I haven't found a good way to plot stuff into country maps... Maybe one of the demos of D3.js has something usable?
[Discipulus]: i need to use css to get and colorize various different IDs?
[Corion]: I haven't used it, but http://datamaps. github.io/ looks promising
[Discipulus]: thanks.. a more perlish solution?

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (10)
As of 2017-03-23 09:26 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Should Pluto Get Its Planethood Back?



    Results (285 votes). Check out past polls.