Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 0.9.4

Bug #2346 SetColumn - Format not set
Submitted: 2004-09-16 01:57 UTC
From: derrickbtan dot lists at gmail dot com Assigned:
Status: No Feedback Package: Spreadsheet_Excel_Writer
PHP Version: 5.0.1 OS: Windows 2000
Roadmaps: (Not assigned)    
Subscription  
Comments Add Comment Add patch


Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know! Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem : 41 - 29 = ?

 
 [2004-09-16 01:57 UTC] derrickbtan dot lists at gmail dot com
Description: ------------ Spreadsheet_Excel_Writer 0.8 OLE 0.5 The sample code provided is a just a little bit of the data I want to write, but it should be enough to reproduce the problem. I have tried putting the setcolumns and format call before the data is written as well (the sample code tries formatting after). Reproduce code: --------------- $empName = $emp->getEmployeeName(); $reportDate = date( "Y/m/d", $rep->getReportDate() ); $ws = $this->xls->addWorkSheet( "$empName - $reportDate" ); // Write the data $col = 0; $row = 0; // Print the date (A1) $ws->write( $row, $col++, $this->configArray['l_date'] ); $ws->write( $row++, $col--, $reportDate ); // Print the division (A2) $ws->write( $row, $col++, $this->configArray['l_division'] ); $ws->write( $row++, $col--, $div->getName() ); /////////////// // . . . ////////////// // Data format $this->format['data'] = $this->xls->addFormat( array( 'size' => 10, 'align' => 'right' ) ); ////////////// // Set column $ws->setColumn( 0, 2, 20, $this->format['data'] ); Expected result: ---------------- In the example provided, I would expect all alignment to be down the right side of the columns 0-2 with the column width set to 20. Actual result: -------------- The width is ok, but the format does not occur.

Comments

 [2004-09-16 02:04 UTC] derrickbtan dot lists at gmail dot com
different email.
 [2005-01-06 15:25 UTC] User who submitted this comment has not confirmed identity
If you submitted this note, check your email.If you do not have a message, click here to re-send
MANUAL CONFIRMATION IS NOT POSSIBLE.  Write a message to pear-dev@lists.php.net
to request the confirmation link.  All bugs/comments/patches associated with this

email address will be deleted within 48 hours if the account request is not confirmed!
 [2005-06-28 05:05 UTC] g at funk dot com
the version is 5.0.1, meaning that the object model shouldn't require the &.
 [2005-08-23 14:24 UTC] daniel dot chafen at virgin dot no dot spam
Seting the format works but it is reset if any data is added using the write or writeFormula even when no format attribute is used. It is very frustrating to have to keep adding the format with every write command.
 [2005-11-08 13:33 UTC] xnoguer at php dot net
sample code can't work, so I'm putting this in feedback status until provided a proper sample code.
 [2008-06-12 08:54 UTC] User who submitted this comment has not confirmed identity
If you submitted this note, check your email.If you do not have a message, click here to re-send
MANUAL CONFIRMATION IS NOT POSSIBLE.  Write a message to pear-dev@lists.php.net
to request the confirmation link.  All bugs/comments/patches associated with this

email address will be deleted within 48 hours if the account request is not confirmed!
 [2008-06-12 09:02 UTC] User who submitted this comment has not confirmed identity
If you submitted this note, check your email.If you do not have a message, click here to re-send
MANUAL CONFIRMATION IS NOT POSSIBLE.  Write a message to pear-dev@lists.php.net
to request the confirmation link.  All bugs/comments/patches associated with this

email address will be deleted within 48 hours if the account request is not confirmed!