Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re: Spreadsheet::Read Open File from Variable?

by soonix (Canon)
on Aug 22, 2017 at 07:23 UTC ( [id://1197783]=note: print w/replies, xml ) Need Help??


in reply to Spreadsheet::Read Open File from Variable?

In addition to what huck said, you should replace the line
print $_ . "\n";
by
print ">>$_<<\n";
just in case the 22948850_Config_(10.5).xlsx in c:/scripts/modular_collector/collections has some invisible character in its name, different from the "same" file in the current directory…

Update: "line 59" seems to be way after the call to Spreadsheet::Read->new, also note that the error message talks about method "read" (lower case "r"). Perhaps you copied an old version of that file into your development directory?

Replies are listed 'Best First'.
Re^2: Spreadsheet::Read Open File from Variable?
by CJ2012SXT (Novice) on Aug 22, 2017 at 08:23 UTC
    Line 59 is the correct line number where it calls Spreadsheet::Read->new. I'm on Win32 and do all of my scripting in Notepad++.
      But line 59 of the code you posted is
      $cell = "C" . $rowCnt;
      Any difference between the code you use and the code you post(ed) may impede our ability to help. Problems with copy+paste do exist, yes, but usually they are smaller than those that stem from manually typing and thereby changing the code.
        I'll keep that in mind. I copy pasted the code right out of Notepad++.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1197783]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others examining the Monastery: (4)
As of 2024-04-23 20:32 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found