Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re: Perl 5.8.? and ParseExcel

by BrowserUk (Pope)
on Jul 20, 2004 at 18:32 UTC ( #376049=note: print w/replies, xml ) Need Help??


in reply to Perl 5.8.? and ParseExcel

The only way I can provoke that warning using pack 'C*', is if the input values are > 255? If that's the case, maybe the module should be using 'U*'.


Examine what is said, not who speaks.
"Efficiency is intelligent laziness." -David Dunham
"Think for yourself!" - Abigail
"Memory, processor, disk in that order on the hardware side. Algorithm, algoritm, algorithm on the code side." - tachyon

Replies are listed 'Best First'.
Re^2: Perl 5.8.? and ParseExcel
by sth (Priest) on Jul 20, 2004 at 18:40 UTC

    ...Yes, I should have said > 255(unsigned char).

    ..maybe the module should be using 'U*'.

    I think I did see that idea posted, somewhere in all my searching. I will try to change it and see if it works. Any idea why this is occuring with 5.8? Did Unicode not work in 5.6 ?

      Perl's implementation of unicode changed quite a lot between 5.6.x and 5.8.x. It is, so I read, very much improved in 5.8.x but with that improvement came the need for a few non-backwards compatible changes and some extra warnings it seems. I've yet done precious little with it.


      Examine what is said, not who speaks.
      "Efficiency is intelligent laziness." -David Dunham
      "Think for yourself!" - Abigail
      "Memory, processor, disk in that order on the hardware side. Algorithm, algoritm, algorithm on the code side." - tachyon

        -Thanks for the replies BrowserUk. Right now I put in a hack until I can figure out or find an answer,

        { local *STDERR; open(STDERR, '>/dev/null'); $oBook = $oExcel->Parse($disclaimer) || die "Unable to parse $ +disclaimer"; }

        ..not the right solution, but it works for now.

        Thanks Again, sth

      Well the 'U*' didn't work, the code is parsing the xls file and adding it to a tab in another xls. Spreadsheet::WriteExcel complains about the characters being to wide. I think there has to be something I can set that will avoid this warning. Parse is defaulting to 'C*', because it is not UTF8, as far as I can tell. I saw something about setting LANG=en_us.UTF8. I'll do some more searching, since I really don't know to much about UTF8, in case you haven't noticed. :-)

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://376049]
help
Chatterbox?
[atcroft]: stevieb: Sad to say that I only recently learned that particular trick, but I have since found it very useful.... :)
[james28909]: ill be back with a solution eventually
[stevieb]: it's a reminder to re-inforce it :P
[atcroft]: james28909: That particular questions was a bit of trick, actually (depending on the country you are in). More interesting is, if you are trying to subtract from an epoch time, for instance, you might have to consider when/if DST occurs for a location,
[atcroft]: because you may have to adjust the number of seconds you change from an epoch from 86400 (not to mention leap seconds)....
[atcroft]: james28909: Although if your program is using a database, you might be able to "pass the buck" to the database and ask it to do the date change for you....

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (3)
As of 2017-04-29 04:37 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    I'm a fool:











    Results (531 votes). Check out past polls.