Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation

Re: Set Background Color Using Spreadsheet::SaveParser

by jmcnamara (Monsignor)
on Dec 17, 2012 at 17:13 UTC ( #1009204=note: print w/replies, xml ) Need Help??

in reply to Set Background Color Using Spreadsheet::SaveParser

The get_format() in the first line returns a Spreadsheet::ParseExcel Format object which doesn't have a set_color() method, or set_anything() method since it is a read/information only object.

Possibly you are getting it confused with a Spreadsheet::WriteExcel format method that you have in the same program. If that is the case, then you will have to map the Spreadsheet::ParseExcel format properties to Spreadsheet::WriteExcel format properties, one by one.


  • Comment on Re: Set Background Color Using Spreadsheet::SaveParser

Replies are listed 'Best First'.
Re^2: Set Background Color Using Spreadsheet::SaveParser
by gw1500se (Beadle) on Dec 17, 2012 at 18:45 UTC
    Thanks for the reply. Not exactly confused as much as not understanding the capabilities of each. I thought SaveParser was a combined ParseExcel and WriteExcel, rather than something completely different. Logically, it seems that if I can add rows with SaveParser then I should also be able to set attributes on those rows. In any case, how do I go about updating an existing spreadsheet if not with SaveParser? Do I need to instead use both ParseExcel and WriteExcel instead? Can WriteExcel update and existing spreadsheet?
        Thanks again for the reply but I'm still stuck. If WriteExcel does not let me rewrite and existing spreadsheet and SaveParser does not let me 'set_color' I only see a brute force method to do what I need. I would have to use WriteExcel to create a new spreadsheet, then delete the old one and rename the new one. It seems like I am missing something or there is a big hole in these modules.

        P.S. If there is no 'set_color' method in SaverParser, why am I not getting a run time error when I try to use it?

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others examining the Monastery: (3)
As of 2020-10-28 03:07 GMT
Find Nodes?
    Voting Booth?
    My favourite web site is:

    Results (259 votes). Check out past polls.