<?xml version="1.0"?>
<?xml-stylesheet
href="http://www.w3.org/2000/08/w3c-synd/style.css" type="text/css"
?>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns="http://purl.org/rss/1.0/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" xmlns:admin="http://webns.net/mvcb/" xmlns:content="http://purl.org/rss/1.0/modules/content/">
    <channel rdf:about="http://pear.php.net/bugs/search.php">
    <title>PEAR Bug Search Results</title>
    <link>http://pear.php.net/bugs/search.php?cmd=display&amp;package_name%5B0%5D=Spreadsheet_Excel_Writer</link>
    <description>Search Results</description>
    <dc:language>en-us</dc:language>
    <dc:creator>pear-webmaster@lists.php.net</dc:creator>
    <dc:publisher>pear-webmaster@lists.php.net</dc:publisher>
    <admin:generatorAgent rdf:resource="http://pear.php.net/bugs"/>
    <sy:updatePeriod>hourly</sy:updatePeriod>
    <sy:updateFrequency>1</sy:updateFrequency>
    <sy:updateBase>2000-01-01T12:00+00:00</sy:updateBase>
    <items>
     <rdf:Seq>
      <rdf:li rdf:resource="http://pear.php.net/bug/16843" />
      <rdf:li rdf:resource="http://pear.php.net/bug/16793" />
      <rdf:li rdf:resource="http://pear.php.net/bug/16678" />
      <rdf:li rdf:resource="http://pear.php.net/bug/16634" />
      <rdf:li rdf:resource="http://pear.php.net/bug/16620" />
      <rdf:li rdf:resource="http://pear.php.net/bug/16541" />
      <rdf:li rdf:resource="http://pear.php.net/bug/16454" />
      <rdf:li rdf:resource="http://pear.php.net/bug/16030" />
      <rdf:li rdf:resource="http://pear.php.net/bug/16025" />
      <rdf:li rdf:resource="http://pear.php.net/bug/14834" />
      <rdf:li rdf:resource="http://pear.php.net/bug/14738" />
      <rdf:li rdf:resource="http://pear.php.net/bug/14690" />
      <rdf:li rdf:resource="http://pear.php.net/bug/14515" />
      <rdf:li rdf:resource="http://pear.php.net/bug/14404" />
      <rdf:li rdf:resource="http://pear.php.net/bug/14203" />
      <rdf:li rdf:resource="http://pear.php.net/bug/14139" />
      <rdf:li rdf:resource="http://pear.php.net/bug/13752" />
      <rdf:li rdf:resource="http://pear.php.net/bug/13743" />
      <rdf:li rdf:resource="http://pear.php.net/bug/13492" />
      <rdf:li rdf:resource="http://pear.php.net/bug/13486" />
      <rdf:li rdf:resource="http://pear.php.net/bug/13171" />
      <rdf:li rdf:resource="http://pear.php.net/bug/13149" />
      <rdf:li rdf:resource="http://pear.php.net/bug/12848" />
      <rdf:li rdf:resource="http://pear.php.net/bug/12684" />
      <rdf:li rdf:resource="http://pear.php.net/bug/12629" />
      <rdf:li rdf:resource="http://pear.php.net/bug/12362" />
      <rdf:li rdf:resource="http://pear.php.net/bug/12212" />
      <rdf:li rdf:resource="http://pear.php.net/bug/12109" />
      <rdf:li rdf:resource="http://pear.php.net/bug/9879" />
      <rdf:li rdf:resource="http://pear.php.net/bug/9814" />
      <rdf:li rdf:resource="http://pear.php.net/bug/9605" />
      <rdf:li rdf:resource="http://pear.php.net/bug/9604" />
      <rdf:li rdf:resource="http://pear.php.net/bug/9533" />
      <rdf:li rdf:resource="http://pear.php.net/bug/9259" />
      <rdf:li rdf:resource="http://pear.php.net/bug/9126" />
      <rdf:li rdf:resource="http://pear.php.net/bug/9062" />
      <rdf:li rdf:resource="http://pear.php.net/bug/8967" />
      <rdf:li rdf:resource="http://pear.php.net/bug/8733" />
      <rdf:li rdf:resource="http://pear.php.net/bug/8601" />
      <rdf:li rdf:resource="http://pear.php.net/bug/8323" />
      <rdf:li rdf:resource="http://pear.php.net/bug/8303" />
      <rdf:li rdf:resource="http://pear.php.net/bug/7672" />
      <rdf:li rdf:resource="http://pear.php.net/bug/7504" />
      <rdf:li rdf:resource="http://pear.php.net/bug/5560" />
      <rdf:li rdf:resource="http://pear.php.net/bug/5347" />
      <rdf:li rdf:resource="http://pear.php.net/bug/4665" />
      <rdf:li rdf:resource="http://pear.php.net/bug/3203" />
      <rdf:li rdf:resource="http://pear.php.net/bug/3148" />
      <rdf:li rdf:resource="http://pear.php.net/bug/2862" />
      <rdf:li rdf:resource="http://pear.php.net/bug/2146" />

     </rdf:Seq>
    </items>
  </channel>

  <image rdf:about="http://pear.php.net/gifs/pearsmall.gif">
    <title>PEAR Bugs</title>
    <url>http://pear.php.net/gifs/pearsmall.gif</url>
    <link>http://pear.php.net/bugs</link>
  </image>

    <item rdf:about="http://pear.php.net/bug/16843">
      <title>Spreadsheet_Excel_Writer: Feature/Change Request 16843 [Verified] Conditional Formatting</title>
      <link>http://pear.php.net/bugs/16843</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by marine_nl_1976
2009-11-27T21:11:36+00:00
PHP: 5.3.0 OS: Win XP Package Version: 0.9.1

Description:
------------
I would really like to be able to add Conditional Formatting as in Excel (setting 3 conditions to the format of a cell based on the value of the cell).

If this is already possible please let me know where to find documentation and code-examples, because I couldn't find it.</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by marine_nl_1976
2009-11-27T21:11:36+00:00
PHP: 5.3.0 OS: Win XP Package Version: 0.9.1

Description:
------------
I would really like to be able to add Conditional Formatting as in Excel (setting 3 conditions to the format of a cell based on the value of the cell).

If this is already possible please let me know where to find documentation and code-examples, because I couldn't find it.</pre>]]></description>
      <dc:date>2009-11-27T21:11:36+00:00</dc:date>
      <dc:creator>jeroengoddijn &amp;#x61;&amp;#116; hotmail &amp;#x64;&amp;#111;&amp;#x74; com</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Feature/Change Request</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/16793">
      <title>Spreadsheet_Excel_Writer: Bug 16793 [Open] formula not working in exported excel sheet.</title>
      <link>http://pear.php.net/bugs/16793</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by kombaa
2009-11-17T12:33:45+00:00
PHP: 4.4.5 OS: windows xp Package Version: 0.9.1

Description:
------------
am able to export mysql data to excel file.But now i want to count all desk top computers available in inventory via excel sheet.I put the formula as shown in code below.

$worksheet-&gt;write(4, 1,  '=COUNTIF(A8:A100,&quot;DESK TOP&quot;)');
The rusult in excel sheet is not as desired, it gives cell with with text written #VALUE! until i double click it gives me number.So how to solve the problem?Help me</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by kombaa
2009-11-17T12:33:45+00:00
PHP: 4.4.5 OS: windows xp Package Version: 0.9.1

Description:
------------
am able to export mysql data to excel file.But now i want to count all desk top computers available in inventory via excel sheet.I put the formula as shown in code below.

$worksheet-&gt;write(4, 1,  '=COUNTIF(A8:A100,&quot;DESK TOP&quot;)');
The rusult in excel sheet is not as desired, it gives cell with with text written #VALUE! until i double click it gives me number.So how to solve the problem?Help me</pre>]]></description>
      <dc:date>2009-11-17T12:33:45+00:00</dc:date>
      <dc:creator>fkomba09 &amp;#x61;&amp;#116; yahoo &amp;#x64;&amp;#111;&amp;#x74; com</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/16678">
      <title>Spreadsheet_Excel_Writer: Bug 16678 [Assigned] In PHP 5.3 get errors on lines 186, 195</title>
      <link>http://pear.php.net/bugs/16678</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by steinerd
2009-10-05T13:53:36+00:00
PHP: 5.3.0 OS: Windows 2003 Server Package Version: 0.9.1

Description:
------------
Deprecated: Assigning the return value of new by reference is deprecated in C:\websoftware\php\PEAR\Spreadsheet\Excel\Writer\Workbook.php on line 186

Deprecated: Assigning the return value of new by reference is deprecated in C:\websoftware\php\PEAR\Spreadsheet\Excel\Writer\Workbook.php on line 195

186   &amp;     $this-&gt;_parser           = new Spreadsheet_Excel_Writer_Parser($this-&gt;_byte_order, $this-&gt;_BIFF_version);

195  &amp;   $this-&gt;_tmp_format       = new Spreadsheet_Excel_Writer_Format($this-&gt;_BIFF_version);


Test script:
---------------
186    $this-&gt;_parser           = new Spreadsheet_Excel_Writer_Parser($this-&gt;_byte_order, $this-&gt;_BIFF_version);

195  $this-&gt;_tmp_format       = new Spreadsheet_Excel_Writer_Format($this-&gt;_BIFF_version);

//Removed the &quot;&amp;&quot; in both these lines

Expected result:
----------------
This fixed my problem in PHP 5.3</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by steinerd
2009-10-05T13:53:36+00:00
PHP: 5.3.0 OS: Windows 2003 Server Package Version: 0.9.1

Description:
------------
Deprecated: Assigning the return value of new by reference is deprecated in C:\websoftware\php\PEAR\Spreadsheet\Excel\Writer\Workbook.php on line 186

Deprecated: Assigning the return value of new by reference is deprecated in C:\websoftware\php\PEAR\Spreadsheet\Excel\Writer\Workbook.php on line 195

186   &amp;     $this-&gt;_parser           = new Spreadsheet_Excel_Writer_Parser($this-&gt;_byte_order, $this-&gt;_BIFF_version);

195  &amp;   $this-&gt;_tmp_format       = new Spreadsheet_Excel_Writer_Format($this-&gt;_BIFF_version);


Test script:
---------------
186    $this-&gt;_parser           = new Spreadsheet_Excel_Writer_Parser($this-&gt;_byte_order, $this-&gt;_BIFF_version);

195  $this-&gt;_tmp_format       = new Spreadsheet_Excel_Writer_Format($this-&gt;_BIFF_version);

//Removed the &quot;&amp;&quot; in both these lines

Expected result:
----------------
This fixed my problem in PHP 5.3</pre>]]></description>
      <dc:date>2009-11-29T17:46:59+00:00</dc:date>
      <dc:creator>denver &amp;#x61;&amp;#116; ventrac &amp;#x64;&amp;#111;&amp;#x74; com</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/16634">
      <title>Spreadsheet_Excel_Writer: Bug 16634 [Open] Cannot reassign a color to a cell</title>
      <link>http://pear.php.net/bugs/16634</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by frameone
2009-09-22T23:48:16+00:00
PHP: 5.3.0 OS: Windows XP Package Version: 0.9.1

Description:
------------
If you try to reassign a color to a reused Format-Objekt, the color will not applied to the cell.

Of course, you can create a new Format-object for each cell, but this will result in a fatal memory leak in a bigger document!

Test script:
---------------
require_once 'Spreadsheet/Excel/Writer.php';

$workbook  = new Spreadsheet_Excel_Writer();
$worksheet = &amp;$workbook-&gt;addWorksheet('SetColor');

// which guy has put this into a loop? o.O
$format = $workbook-&gt;addFormat();

for ($inc =0; $inc&lt;64; $inc++) {
    // Sets the color of a cell's content
    $format-&gt;setColor($inc);
    $worksheet-&gt;write($inc, 0, 'Color (index '.$inc.')', $format);
}
$workbook-&gt;send('setColor.xls');
$workbook-&gt;close();</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by frameone
2009-09-22T23:48:16+00:00
PHP: 5.3.0 OS: Windows XP Package Version: 0.9.1

Description:
------------
If you try to reassign a color to a reused Format-Objekt, the color will not applied to the cell.

Of course, you can create a new Format-object for each cell, but this will result in a fatal memory leak in a bigger document!

Test script:
---------------
require_once 'Spreadsheet/Excel/Writer.php';

$workbook  = new Spreadsheet_Excel_Writer();
$worksheet = &amp;$workbook-&gt;addWorksheet('SetColor');

// which guy has put this into a loop? o.O
$format = $workbook-&gt;addFormat();

for ($inc =0; $inc&lt;64; $inc++) {
    // Sets the color of a cell's content
    $format-&gt;setColor($inc);
    $worksheet-&gt;write($inc, 0, 'Color (index '.$inc.')', $format);
}
$workbook-&gt;send('setColor.xls');
$workbook-&gt;close();</pre>]]></description>
      <dc:date>2009-09-22T23:48:16+00:00</dc:date>
      <dc:creator>rene &amp;#x61;&amp;#116; event-solutions &amp;#x64;&amp;#111;&amp;#x74; at</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/16620">
      <title>Spreadsheet_Excel_Writer: Bug 16620 [Open] With SetVersion(8) RepaetRows does not work</title>
      <link>http://pear.php.net/bugs/16620</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by nextgate
2009-09-16T20:24:11+00:00
PHP: Irrelevant OS: WIN XP Package Version: 0.9.1

Description:
------------
With SetVersion(8) applied in the code ReatRows functionality is lost. 
A mesage for Excel recovering file is shown and the Excel fiele crashes and loses all format

Test script:
---------------
$this-&gt;workbook-&gt;setVersion(8);
$this-&gt;worksheet = $this-&gt;workbook-&gt;addWorksheet( &quot;test' );
...
...
$this-&gt;worksheet-&gt;repeatRows(0);

Expected result:
----------------
Get the first row repeated for printing.

Actual result:
--------------
Alert message for file recovery in Microsoft Excel</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by nextgate
2009-09-16T20:24:11+00:00
PHP: Irrelevant OS: WIN XP Package Version: 0.9.1

Description:
------------
With SetVersion(8) applied in the code ReatRows functionality is lost. 
A mesage for Excel recovering file is shown and the Excel fiele crashes and loses all format

Test script:
---------------
$this-&gt;workbook-&gt;setVersion(8);
$this-&gt;worksheet = $this-&gt;workbook-&gt;addWorksheet( &quot;test' );
...
...
$this-&gt;worksheet-&gt;repeatRows(0);

Expected result:
----------------
Get the first row repeated for printing.

Actual result:
--------------
Alert message for file recovery in Microsoft Excel</pre>]]></description>
      <dc:date>2009-09-16T20:24:11+00:00</dc:date>
      <dc:creator>alexanderguevara &amp;#x61;&amp;#116; gmail &amp;#x64;&amp;#111;&amp;#x74; com</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/16541">
      <title>Spreadsheet_Excel_Writer: Feature/Change Request 16541 [Verified] Need ability to get raw output of Spreadsheet document</title>
      <link>http://pear.php.net/bugs/16541</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by jasonlloyd
2009-08-20T04:31:42+00:00
PHP: 5.1.4 OS: All Package Version: 0.9.1

Description:
------------
For use cases other than sending to a browser (such as sending in a multi-part MIME encoded email) a method that returns the raw spreadsheet would be nice.  Right now I am hijacking the output buffer to capture the results of $workbook-&gt;close(); in order to capture output into a variable.

Test script:
---------------
//my naughty workaround:
ob_start();//start buffering to capture contents of excel document.
$workbook-&gt;close();
$document = ob_get_contents();
ob_end_clean();//clean out this buffer, and turn off buffering.

//should really look like:
$document = $workbook-&gt;getRaw(); //or whatever name sounds good.</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by jasonlloyd
2009-08-20T04:31:42+00:00
PHP: 5.1.4 OS: All Package Version: 0.9.1

Description:
------------
For use cases other than sending to a browser (such as sending in a multi-part MIME encoded email) a method that returns the raw spreadsheet would be nice.  Right now I am hijacking the output buffer to capture the results of $workbook-&gt;close(); in order to capture output into a variable.

Test script:
---------------
//my naughty workaround:
ob_start();//start buffering to capture contents of excel document.
$workbook-&gt;close();
$document = ob_get_contents();
ob_end_clean();//clean out this buffer, and turn off buffering.

//should really look like:
$document = $workbook-&gt;getRaw(); //or whatever name sounds good.</pre>]]></description>
      <dc:date>2009-11-29T18:00:57+00:00</dc:date>
      <dc:creator>jason &amp;#x61;&amp;#116; spotonrecruiting &amp;#x64;&amp;#111;&amp;#x74; com</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Feature/Change Request</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/16454">
      <title>Spreadsheet_Excel_Writer: Feature/Change Request 16454 [Open] New Feature Needed</title>
      <link>http://pear.php.net/bugs/16454</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by bernstml
2009-07-20T17:27:00+00:00
PHP: 5.3.0 OS: Linux Package Version: 0.9.1

Description:
------------
It is imperative that you allow certain words in a cell to have different colors than other words.  For example: Bob went to the store.  Lets say I wanted to highlight or change the text color of the word &quot;store&quot;  This can be done in Excel, but not using this library.

Test script:
---------------
	$worksheet-&gt;writeString($rowCount, $fieldCount, &quot;Some Text&quot;, $$someFormat);

	$worksheet-&gt;writeString($rowCount, $fieldCount, &quot; Other Text&quot;, $$someOtherFormat);

Expected result:
----------------
Some TextOther Text but other Other Text has a different format.

Actual result:
--------------
Error</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by bernstml
2009-07-20T17:27:00+00:00
PHP: 5.3.0 OS: Linux Package Version: 0.9.1

Description:
------------
It is imperative that you allow certain words in a cell to have different colors than other words.  For example: Bob went to the store.  Lets say I wanted to highlight or change the text color of the word &quot;store&quot;  This can be done in Excel, but not using this library.

Test script:
---------------
	$worksheet-&gt;writeString($rowCount, $fieldCount, &quot;Some Text&quot;, $$someFormat);

	$worksheet-&gt;writeString($rowCount, $fieldCount, &quot; Other Text&quot;, $$someOtherFormat);

Expected result:
----------------
Some TextOther Text but other Other Text has a different format.

Actual result:
--------------
Error</pre>]]></description>
      <dc:date>2009-07-20T17:27:00+00:00</dc:date>
      <dc:creator>matthew &amp;#x64;&amp;#111;&amp;#x74; l &amp;#x64;&amp;#111;&amp;#x74; bernstein &amp;#x61;&amp;#116; vanderbilt &amp;#x64;&amp;#111;&amp;#x74; edu</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Feature/Change Request</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/16030">
      <title>Spreadsheet_Excel_Writer: Bug 16030 [Verified] Absolute ranges fail</title>
      <link>http://pear.php.net/bugs/16030</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by jabouillei
2009-03-13T03:36:00+00:00
PHP: 5.2.5 OS: SuSE and Cent OS Package Version: 0.9.2

Description:
------------
Attempting to write the following formula resulted in a &quot;')' token expected&quot; message appearing in the cell instead of the desired formula:
=(0+SUMPRODUCT(M6:M14;$G6:$G14)+M15*$G15)

Fortunately, this is easy to fix (after hours of debugging).  Here is how to fix it:
Open Parser.php and find every place that there is a regular expression for a range.  Replace the double quotes that enclose the regular expression with single quotes.  Then re-use a pair of the regular expressions you just updated (one for &quot;:&quot; and one for &quot;..&quot;) in the _convertRange2d function.  The off-the-shelf version of that function doesn't handle &quot;$&quot;s.  You're all set!

Test script:
---------------
=(0+SUMPRODUCT(M6:M14;$G6:$G14)+M15*$G15)

Expected result:
----------------
The formula should appear in the cell.

Actual result:
--------------
&quot;')' token expected&quot; appears in the cell.</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by jabouillei
2009-03-13T03:36:00+00:00
PHP: 5.2.5 OS: SuSE and Cent OS Package Version: 0.9.2

Description:
------------
Attempting to write the following formula resulted in a &quot;')' token expected&quot; message appearing in the cell instead of the desired formula:
=(0+SUMPRODUCT(M6:M14;$G6:$G14)+M15*$G15)

Fortunately, this is easy to fix (after hours of debugging).  Here is how to fix it:
Open Parser.php and find every place that there is a regular expression for a range.  Replace the double quotes that enclose the regular expression with single quotes.  Then re-use a pair of the regular expressions you just updated (one for &quot;:&quot; and one for &quot;..&quot;) in the _convertRange2d function.  The off-the-shelf version of that function doesn't handle &quot;$&quot;s.  You're all set!

Test script:
---------------
=(0+SUMPRODUCT(M6:M14;$G6:$G14)+M15*$G15)

Expected result:
----------------
The formula should appear in the cell.

Actual result:
--------------
&quot;')' token expected&quot; appears in the cell.</pre>]]></description>
      <dc:date>2009-11-29T17:56:07+00:00</dc:date>
      <dc:creator>truth &amp;#x61;&amp;#116; proposaltech &amp;#x64;&amp;#111;&amp;#x74; com</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/16025">
      <title>Spreadsheet_Excel_Writer: Bug 16025 [Open] MERGEDCELLS record split by CONTINUE record</title>
      <link>http://pear.php.net/bugs/16025</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by bjaenichen
2009-03-12T11:36:15+00:00
PHP: Irrelevant OS: openSUSE 10.2 (i586) Package Version: 0.9.1

Description:
------------
If more mergedcells ranges declared as record size limit allows in one MERGEDCELLS-record a CONTINUE-record will split MERGEDCELLS-record into pieces.

This is not supported by MS-Excel, OpenOffice fileformat documentation describes how to store it correctly:

&quot;If the record size exceeds the limit, it is not continued with a CONTINUE record, but another self-contained MERGEDCELLS
record is started. The limit of 8224 bytes per record results in a maximum number of 1027 merged ranges.&quot;

Attached patch will fix Worksheet.php.

Test script:
---------------
&lt;?PHP
include &quot;Writer.php&quot;;
$wb = new Spreadsheet_Excel_Writer(&quot;/tmp/test_merged_cells.xls&quot;);
$wb-&gt;setVersion(8);
$wb-&gt;_codepage = 0x4b0;
$wb-&gt;worksheetcounter = 0;
$wb-&gt;localworksheets[$wb-&gt;worksheetcounter] = &amp;$wb-&gt;addWorksheet(&quot;Table&quot;.$wb-&gt;worksheetcounter);
for($i = 0; $i &lt; 1030; $i++)
  {
    $wb-&gt;localworksheets[$wb-&gt;worksheetcounter]-&gt;writeString($i, 0, $i);
    $wb-&gt;localworksheets[$wb-&gt;worksheetcounter]-&gt;setMerge($i, 0, $i, 1);
  }
$wb-&gt;close();
?&gt;


Expected result:
----------------
MS-Excel opens the resulting XLS-testfile without any warning.

Actual result:
--------------
MS-Excel crashes if opening the resulting XLS-testfile.</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by bjaenichen
2009-03-12T11:36:15+00:00
PHP: Irrelevant OS: openSUSE 10.2 (i586) Package Version: 0.9.1

Description:
------------
If more mergedcells ranges declared as record size limit allows in one MERGEDCELLS-record a CONTINUE-record will split MERGEDCELLS-record into pieces.

This is not supported by MS-Excel, OpenOffice fileformat documentation describes how to store it correctly:

&quot;If the record size exceeds the limit, it is not continued with a CONTINUE record, but another self-contained MERGEDCELLS
record is started. The limit of 8224 bytes per record results in a maximum number of 1027 merged ranges.&quot;

Attached patch will fix Worksheet.php.

Test script:
---------------
&lt;?PHP
include &quot;Writer.php&quot;;
$wb = new Spreadsheet_Excel_Writer(&quot;/tmp/test_merged_cells.xls&quot;);
$wb-&gt;setVersion(8);
$wb-&gt;_codepage = 0x4b0;
$wb-&gt;worksheetcounter = 0;
$wb-&gt;localworksheets[$wb-&gt;worksheetcounter] = &amp;$wb-&gt;addWorksheet(&quot;Table&quot;.$wb-&gt;worksheetcounter);
for($i = 0; $i &lt; 1030; $i++)
  {
    $wb-&gt;localworksheets[$wb-&gt;worksheetcounter]-&gt;writeString($i, 0, $i);
    $wb-&gt;localworksheets[$wb-&gt;worksheetcounter]-&gt;setMerge($i, 0, $i, 1);
  }
$wb-&gt;close();
?&gt;


Expected result:
----------------
MS-Excel opens the resulting XLS-testfile without any warning.

Actual result:
--------------
MS-Excel crashes if opening the resulting XLS-testfile.</pre>]]></description>
      <dc:date>2009-03-12T11:36:15+00:00</dc:date>
      <dc:creator>bernd &amp;#x64;&amp;#111;&amp;#x74; jaenichen &amp;#x61;&amp;#116; globalpark &amp;#x64;&amp;#111;&amp;#x74; com</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/14834">
      <title>Spreadsheet_Excel_Writer: Bug 14834 [Open] Fatal error: Call to a member function getXfIndex() on a non-object</title>
      <link>http://pear.php.net/bugs/14834</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by denis
2008-10-20T07:18:28+00:00
PHP: 5.2.6 OS: windows xp Package Version: 

Description:
------------
I would like to increase row height, that was visible all entire text of cells

Test script:
---------------
$counter = 1;
foreach($serviceNames as $el){
  $sheet-&gt;setRow(1,$counter,30);
  $sheet-&gt;write(1,$counter++,$el,$headerFormat);
}


Expected result:
----------------
increased rows height

Actual result:
--------------
Fatal error: Call to a member function getXfIndex() on a non-object in C:\Apache\...\Writer\Worksheet.php on line 1234</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by denis
2008-10-20T07:18:28+00:00
PHP: 5.2.6 OS: windows xp Package Version: 

Description:
------------
I would like to increase row height, that was visible all entire text of cells

Test script:
---------------
$counter = 1;
foreach($serviceNames as $el){
  $sheet-&gt;setRow(1,$counter,30);
  $sheet-&gt;write(1,$counter++,$el,$headerFormat);
}


Expected result:
----------------
increased rows height

Actual result:
--------------
Fatal error: Call to a member function getXfIndex() on a non-object in C:\Apache\...\Writer\Worksheet.php on line 1234</pre>]]></description>
      <dc:date>2008-10-25T01:38:37+00:00</dc:date>
      <dc:creator>amkarovec &amp;#x61;&amp;#116; gmail &amp;#x64;&amp;#111;&amp;#x74; com</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/14738">
      <title>Spreadsheet_Excel_Writer: Bug 14738 [Verified] Euro symbol not working in formats</title>
      <link>http://pear.php.net/bugs/14738</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by tuggie
2008-10-03T10:57:52+00:00
PHP: 5.2.6 OS: Windows XP Package Version: 0.9.2

Description:
------------
I cannot get the Euro symbol to print in formatted numbers in spreadsheets using BIFF8, although it works fine with BIFF5. However, I have to use BIFF8 as I need to use long labels that are truncated in BIFF5. Any suggestions? Any ideas for workarounds?

Test script:
---------------
&lt;?php

require_once('Spreadsheet/Excel/Writer.php');
 
$workbook = new Spreadsheet_Excel_Writer();
$workbook-&gt;setVersion(8);
$worksheet =&amp; $workbook-&gt;addWorksheet();
$worksheet-&gt;setInputEncoding('Windows-1252' );

$worksheet-&gt;write(1,0,'Â¤');

$strEuroFormat = '#,##0.00';
$objEuroFormat = &amp;$workbook-&gt;addFormat();
$objEuroFormat-&gt;setNumFormat($strEuroFormat);
$objEuroFormat-&gt;setAlign('right');


$worksheet-&gt;writeNumber(2,0,250, $objEuroFormat);

$workbook-&gt;send('test.xls');
$workbook-&gt;close();

?&gt;

Expected result:
----------------
Cell (1,0) contains a Euro symbol and cell (2,0) contains 250.00 precedded by a Euro symbol.

Actual result:
--------------
Cell (1,0) contains a Euro symbol but cell (2,0) contains 250.00 precedded by a ? in a square.</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by tuggie
2008-10-03T10:57:52+00:00
PHP: 5.2.6 OS: Windows XP Package Version: 0.9.2

Description:
------------
I cannot get the Euro symbol to print in formatted numbers in spreadsheets using BIFF8, although it works fine with BIFF5. However, I have to use BIFF8 as I need to use long labels that are truncated in BIFF5. Any suggestions? Any ideas for workarounds?

Test script:
---------------
&lt;?php

require_once('Spreadsheet/Excel/Writer.php');
 
$workbook = new Spreadsheet_Excel_Writer();
$workbook-&gt;setVersion(8);
$worksheet =&amp; $workbook-&gt;addWorksheet();
$worksheet-&gt;setInputEncoding('Windows-1252' );

$worksheet-&gt;write(1,0,'Â¤');

$strEuroFormat = '#,##0.00';
$objEuroFormat = &amp;$workbook-&gt;addFormat();
$objEuroFormat-&gt;setNumFormat($strEuroFormat);
$objEuroFormat-&gt;setAlign('right');


$worksheet-&gt;writeNumber(2,0,250, $objEuroFormat);

$workbook-&gt;send('test.xls');
$workbook-&gt;close();

?&gt;

Expected result:
----------------
Cell (1,0) contains a Euro symbol and cell (2,0) contains 250.00 precedded by a Euro symbol.

Actual result:
--------------
Cell (1,0) contains a Euro symbol but cell (2,0) contains 250.00 precedded by a ? in a square.</pre>]]></description>
      <dc:date>2009-11-29T00:56:33+00:00</dc:date>
      <dc:creator>paul &amp;#x61;&amp;#116; guardbase &amp;#x64;&amp;#111;&amp;#x74; co &amp;#x64;&amp;#111;&amp;#x74; uk</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/14690">
      <title>Spreadsheet_Excel_Writer: Feature/Change Request 14690 [Open] writeNote() addition</title>
      <link>http://pear.php.net/bugs/14690</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by wiesemann
2008-09-22T09:44:43+00:00
PHP: Irrelevant OS: Irrelevant Package Version: 

Manual page: package.fileformats.spreadsheet-excel-writer.spreadsheet-excel-writer-worksheet.writenote.php

It would be great if the writeNote() fonction could work with custom width and height, cause when the text written on note is too long, it doesn't display right...</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by wiesemann
2008-09-22T09:44:43+00:00
PHP: Irrelevant OS: Irrelevant Package Version: 

Manual page: package.fileformats.spreadsheet-excel-writer.spreadsheet-excel-writer-worksheet.writenote.php

It would be great if the writeNote() fonction could work with custom width and height, cause when the text written on note is too long, it doesn't display right...</pre>]]></description>
      <dc:date>2008-09-22T09:45:58+00:00</dc:date>
      <dc:creator>wiesemann &amp;#x61;&amp;#116; php &amp;#x64;&amp;#111;&amp;#x74; net</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Feature/Change Request</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/14515">
      <title>Spreadsheet_Excel_Writer: Bug 14515 [Open] writeUrl only uses writeString, never writeNumber</title>
      <link>http://pear.php.net/bugs/14515</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by gpalsson
2008-08-18T06:14:54+00:00
PHP: 5.2.6 OS: fedora Package Version: 0.9.1

Description:
------------
When making a link with createUrl function, numbers cannot later be used for formulas like SUM(1A:2A) because createUrl always uses createString for making the text in the field.

Test script:
---------------
$worksheet-&gt;writeUrl($vRow, $vCol, $vProductUrl, $vProductPrice, $format_blue_number);

Expected result:
----------------
A link with a number visible should be inserted into the sheet.

Actual result:
--------------
A link with a string is inserted to the sheet. Now formulas concerning numbers are not working with these cells.
It can be fixed easily by changing line 1881 in WorkSheet to         $str_error = is_numeric($str) ? $this-&gt;writeNumber($row1, $col1, $str, $format) : $this-&gt;writeString($row1, $col1, $str, $format);</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by gpalsson
2008-08-18T06:14:54+00:00
PHP: 5.2.6 OS: fedora Package Version: 0.9.1

Description:
------------
When making a link with createUrl function, numbers cannot later be used for formulas like SUM(1A:2A) because createUrl always uses createString for making the text in the field.

Test script:
---------------
$worksheet-&gt;writeUrl($vRow, $vCol, $vProductUrl, $vProductPrice, $format_blue_number);

Expected result:
----------------
A link with a number visible should be inserted into the sheet.

Actual result:
--------------
A link with a string is inserted to the sheet. Now formulas concerning numbers are not working with these cells.
It can be fixed easily by changing line 1881 in WorkSheet to         $str_error = is_numeric($str) ? $this-&gt;writeNumber($row1, $col1, $str, $format) : $this-&gt;writeString($row1, $col1, $str, $format);</pre>]]></description>
      <dc:date>2008-08-18T06:18:08+00:00</dc:date>
      <dc:creator>gpalsson &amp;#x61;&amp;#116; live &amp;#x64;&amp;#111;&amp;#x74; dk</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/14404">
      <title>Spreadsheet_Excel_Writer: Feature/Change Request 14404 [Open] WriteNote() =&gt; Note too small in Excelsheet</title>
      <link>http://pear.php.net/bugs/14404</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by webassistants
2008-07-25T04:10:18+00:00
PHP: 5.2.6 OS: WinXP Package Version: 0.9.1

Description:
------------
Is there any possibility to enlarge the width and height of a note or dynamically? I cannot read the whole text in my note, because it is definitely to small.</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by webassistants
2008-07-25T04:10:18+00:00
PHP: 5.2.6 OS: WinXP Package Version: 0.9.1

Description:
------------
Is there any possibility to enlarge the width and height of a note or dynamically? I cannot read the whole text in my note, because it is definitely to small.</pre>]]></description>
      <dc:date>2008-07-25T04:10:18+00:00</dc:date>
      <dc:creator>tim &amp;#x64;&amp;#111;&amp;#x74; rutte &amp;#x61;&amp;#116; web-assistants &amp;#x64;&amp;#111;&amp;#x74; de</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Feature/Change Request</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/14203">
      <title>Spreadsheet_Excel_Writer: Bug 14203 [Open] Unicode support broken</title>
      <link>http://pear.php.net/bugs/14203</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by twu2
2008-06-21T01:58:05+00:00
PHP: Irrelevant OS: Irrelevant Package Version: 0.9.1

Description:
------------
When use unicode encoding, if the file large than 100K, it might generate a damaged excel file.</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by twu2
2008-06-21T01:58:05+00:00
PHP: Irrelevant OS: Irrelevant Package Version: 0.9.1

Description:
------------
When use unicode encoding, if the file large than 100K, it might generate a damaged excel file.</pre>]]></description>
      <dc:date>2008-06-21T01:58:05+00:00</dc:date>
      <dc:creator>wu &amp;#x64;&amp;#111;&amp;#x74; tommy &amp;#x61;&amp;#116; gmail &amp;#x64;&amp;#111;&amp;#x74; com</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/14139">
      <title>Spreadsheet_Excel_Writer: Bug 14139 [Open] Thick bottom border problem with writeFormula()</title>
      <link>http://pear.php.net/bugs/14139</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by polskicoder
2008-06-13T22:52:18+00:00
PHP: 5.1.6 OS: Linux RH Fedora  / WinXP Package Version: 0.9.1

Description:
------------
When using writeFormula() function on a cell with Thick Borders format, the bottom border of that cell has a thin border.

Also tried without success:
- changing the border, background and text colours
- increasing the height of the cell
- drawing a TOP thick border in the cell directly below

Fyi, writeNumber(), writeString(), write() works correctly

Test script:
---------------
$workbook = new Spreadsheet_Excel_Writer();
$workbook-&gt;setVersion(8);
$workbook-&gt;setTempDir(&quot;./tmp&quot;);
$workbook-&gt;send('test.xls');
$worksheet =&amp; $workbook-&gt;addWorksheet('test');

$formats = array(); 
$common_format = array('font' =&gt; 'Arial');  
$formats[0] =&amp; $workbook-&gt;addformat($common_format);
$formats[0]-&gt;setBorderColor('gray'); // border styling
$formats[0]-&gt;setTop(2);
$formats[0]-&gt;setBottom(2);
$formats[0]-&gt;setLeft(2);
$formats[0]-&gt;setRight(2);
$formats[0]-&gt;setLocked();

$worksheet-&gt;writeNumber(1, 1, 1000, $formats[0]); // write a number
$worksheet-&gt;writeFormula(3, 1, '=A1', $formats[0]); // formula to get that number

Expected result:
----------------
Both cells (number and formula) should have thick borders all around.

Actual result:
--------------
Only the cell with the number has all thick borders. Cell with the formula has thick top-left-right borders, but a thin bottom border.</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by polskicoder
2008-06-13T22:52:18+00:00
PHP: 5.1.6 OS: Linux RH Fedora  / WinXP Package Version: 0.9.1

Description:
------------
When using writeFormula() function on a cell with Thick Borders format, the bottom border of that cell has a thin border.

Also tried without success:
- changing the border, background and text colours
- increasing the height of the cell
- drawing a TOP thick border in the cell directly below

Fyi, writeNumber(), writeString(), write() works correctly

Test script:
---------------
$workbook = new Spreadsheet_Excel_Writer();
$workbook-&gt;setVersion(8);
$workbook-&gt;setTempDir(&quot;./tmp&quot;);
$workbook-&gt;send('test.xls');
$worksheet =&amp; $workbook-&gt;addWorksheet('test');

$formats = array(); 
$common_format = array('font' =&gt; 'Arial');  
$formats[0] =&amp; $workbook-&gt;addformat($common_format);
$formats[0]-&gt;setBorderColor('gray'); // border styling
$formats[0]-&gt;setTop(2);
$formats[0]-&gt;setBottom(2);
$formats[0]-&gt;setLeft(2);
$formats[0]-&gt;setRight(2);
$formats[0]-&gt;setLocked();

$worksheet-&gt;writeNumber(1, 1, 1000, $formats[0]); // write a number
$worksheet-&gt;writeFormula(3, 1, '=A1', $formats[0]); // formula to get that number

Expected result:
----------------
Both cells (number and formula) should have thick borders all around.

Actual result:
--------------
Only the cell with the number has all thick borders. Cell with the formula has thick top-left-right borders, but a thin bottom border.</pre>]]></description>
      <dc:date>2008-06-13T23:11:59+00:00</dc:date>
      <dc:creator>batoloco &amp;#x61;&amp;#116; sympatico &amp;#x64;&amp;#111;&amp;#x74; ca</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/13752">
      <title>Spreadsheet_Excel_Writer: Bug 13752 [Open] mergeCells and setTextWrap and text with new lines issue</title>
      <link>http://pear.php.net/bugs/13752</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by hoze
2008-04-23T09:40:50+00:00
PHP: 5.1.6 OS: Linux Package Version: 0.9.1

Description:
------------
mergeCells doesnt expand rows with new line chars. 
if there is no mergeCells the first cell is expanding in height and the whole text is visible if setTextWrap is used.

viewing with ms excel 2003.

Test script:
---------------
$workbook = new Spreadsheet_Excel_Writer('subscriber_agreement_v2.xls');
$worksheet =&amp; $workbook-&gt;addWorksheet('My worksheet');
$format_input_fields =&amp; $workbook-&gt;addFormat();
$format_input_fields-&gt;setAlign('left');
$format_input_fields-&gt;setVAlign('vcenter');
$format_input_fields-&gt;setBorder(3);
$format_input_fields-&gt;setTextWrap();

$worksheet-&gt;setColumn(0,0,25);
$worksheet-&gt;setColumn(0,1,30);
$worksheet-&gt;setColumn(0,2,30);

$worksheet-&gt;write(0, 0, &quot;some long text with \n new line \n another new line. well not so long text \n but has new lines&quot;, $format_input_fields);
$worksheet-&gt;write(0, 1, &quot;&quot;, $format_input_fields);
$worksheet-&gt;write(0, 2, &quot;some text&quot;, $format_input_fields);
$worksheet-&gt;mergeCells($row_number,0,$row_number,1);

$workbook-&gt;close();

Expected result:
----------------
expected to see the row expanding so the whole text to be visible. 

Actual result:
--------------
only the text before the new line character is visible, the height of the row is not changing, the text is shown when clicking on the cell</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by hoze
2008-04-23T09:40:50+00:00
PHP: 5.1.6 OS: Linux Package Version: 0.9.1

Description:
------------
mergeCells doesnt expand rows with new line chars. 
if there is no mergeCells the first cell is expanding in height and the whole text is visible if setTextWrap is used.

viewing with ms excel 2003.

Test script:
---------------
$workbook = new Spreadsheet_Excel_Writer('subscriber_agreement_v2.xls');
$worksheet =&amp; $workbook-&gt;addWorksheet('My worksheet');
$format_input_fields =&amp; $workbook-&gt;addFormat();
$format_input_fields-&gt;setAlign('left');
$format_input_fields-&gt;setVAlign('vcenter');
$format_input_fields-&gt;setBorder(3);
$format_input_fields-&gt;setTextWrap();

$worksheet-&gt;setColumn(0,0,25);
$worksheet-&gt;setColumn(0,1,30);
$worksheet-&gt;setColumn(0,2,30);

$worksheet-&gt;write(0, 0, &quot;some long text with \n new line \n another new line. well not so long text \n but has new lines&quot;, $format_input_fields);
$worksheet-&gt;write(0, 1, &quot;&quot;, $format_input_fields);
$worksheet-&gt;write(0, 2, &quot;some text&quot;, $format_input_fields);
$worksheet-&gt;mergeCells($row_number,0,$row_number,1);

$workbook-&gt;close();

Expected result:
----------------
expected to see the row expanding so the whole text to be visible. 

Actual result:
--------------
only the text before the new line character is visible, the height of the row is not changing, the text is shown when clicking on the cell</pre>]]></description>
      <dc:date>2008-04-23T09:40:50+00:00</dc:date>
      <dc:creator>jfilev &amp;#x61;&amp;#116; yahoo &amp;#x64;&amp;#111;&amp;#x74; com</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/13743">
      <title>Spreadsheet_Excel_Writer: Bug 13743 [Open] _XF gives notice when calling not with object</title>
      <link>http://pear.php.net/bugs/13743</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by medutis
2008-04-22T08:55:17+00:00
PHP: 5.2.5 OS: centos Package Version: 0.9.1

Description:
------------
Worksheet.php:
   
 function _XF(&amp;$format)
    {
        if ($format) {
            return($format-&gt;getXfIndex());
        } else {
            return(0x0F);
        }
    }

sometimes first function line (if ($format)) brings notice, that object cannot be typecasted to boolean, maybe it's php error, but it could be fixed with something like that:

 if (is_object($format) &amp;&amp; get_class($format)=='Spreadsheet_Excel_Writer_Format') {</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by medutis
2008-04-22T08:55:17+00:00
PHP: 5.2.5 OS: centos Package Version: 0.9.1

Description:
------------
Worksheet.php:
   
 function _XF(&amp;$format)
    {
        if ($format) {
            return($format-&gt;getXfIndex());
        } else {
            return(0x0F);
        }
    }

sometimes first function line (if ($format)) brings notice, that object cannot be typecasted to boolean, maybe it's php error, but it could be fixed with something like that:

 if (is_object($format) &amp;&amp; get_class($format)=='Spreadsheet_Excel_Writer_Format') {</pre>]]></description>
      <dc:date>2008-04-22T08:55:17+00:00</dc:date>
      <dc:creator>medutis &amp;#x61;&amp;#116; medutis &amp;#x64;&amp;#111;&amp;#x74; com</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/13492">
      <title>Spreadsheet_Excel_Writer: Feature/Change Request 13492 [Open] Port changes from newer versions of Spreadsheet::WriteExcel</title>
      <link>http://pear.php.net/bugs/13492</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by doconnor
2008-03-25T06:50:05+00:00
PHP: 5.2.5 OS:  Package Version: 0.9.1

Description:
------------
I started looking through Spreadsheet::WriteExcel and comparing it to Spreadsheet_Excel_Writer, hoping to find the cause of many bugs.

The changes, by and large, are not giant; but without test suites, they are hard to verify.

John McNamara sez:
There isn't any public CVS or SVN archive. All of the previous versions are available here as tar balls:

http://backpan.perl.org/authors/id/J/JM/JMCNAMARA/


Most of the PHP ports that I have seen are based on the Excel 5 version of Spreadsheet::WriteExcel, i.e. versions &lt;= 1.01.

There was a significant change in the code base for the Excel 97 versions, i.e. &gt;= 2.01, and there has been 13 not insignificant revisions since then.

In short, getting the PHP versions up to the Perl version is probably a non trivial task. :-)



See also Bug #3986</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by doconnor
2008-03-25T06:50:05+00:00
PHP: 5.2.5 OS:  Package Version: 0.9.1

Description:
------------
I started looking through Spreadsheet::WriteExcel and comparing it to Spreadsheet_Excel_Writer, hoping to find the cause of many bugs.

The changes, by and large, are not giant; but without test suites, they are hard to verify.

John McNamara sez:
There isn't any public CVS or SVN archive. All of the previous versions are available here as tar balls:

http://backpan.perl.org/authors/id/J/JM/JMCNAMARA/


Most of the PHP ports that I have seen are based on the Excel 5 version of Spreadsheet::WriteExcel, i.e. versions &lt;= 1.01.

There was a significant change in the code base for the Excel 97 versions, i.e. &gt;= 2.01, and there has been 13 not insignificant revisions since then.

In short, getting the PHP versions up to the Perl version is probably a non trivial task. :-)



See also Bug #3986</pre>]]></description>
      <dc:date>2008-03-28T19:22:33+00:00</dc:date>
      <dc:creator>daniel &amp;#x64;&amp;#111;&amp;#x74; oconnor &amp;#x61;&amp;#116; gmail &amp;#x64;&amp;#111;&amp;#x74; com</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Feature/Change Request</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/13486">
      <title>Spreadsheet_Excel_Writer: Feature/Change Request 13486 [Open] Set the worksheet direction to right-to-left (RTL)</title>
      <link>http://pear.php.net/bugs/13486</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by dotan
2008-03-24T18:27:24+00:00
PHP: 5.2.0 OS:  Package Version: 0.9.1

Description:
------------
Attached is a patch to Worksheet.php in order to enable setting the worksheet direction to right-to-left (RTL).</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by dotan
2008-03-24T18:27:24+00:00
PHP: 5.2.0 OS:  Package Version: 0.9.1

Description:
------------
Attached is a patch to Worksheet.php in order to enable setting the worksheet direction to right-to-left (RTL).</pre>]]></description>
      <dc:date>2008-03-24T18:27:24+00:00</dc:date>
      <dc:creator>dotan &amp;#x61;&amp;#116; shavitos &amp;#x64;&amp;#111;&amp;#x74; com</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Feature/Change Request</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/13171">
      <title>Spreadsheet_Excel_Writer: Bug 13171 [Open] Built-in styles missing</title>
      <link>http://pear.php.net/bugs/13171</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by rweed
2008-02-21T12:59:37+00:00
PHP: 5.2.5 OS: Linux Package Version: CVS

Description:
------------
With any spreadsheet generated by Spreadsheet_Excel_Writer, if you open it in Excel and click the Currency, Comma, or Percent buttons in the toolbar, you're given the error &quot;Style 'Currency' not found.&quot; (obviously swap Currency for Comma/Percent where appropriate)

This is because the default formats are not being built into the file. To see what I mean, click Format-&gt;Style and notice that &quot;Normal&quot; is the only style in the dropdown. Use Excel to create a new workbook, and go to Format-&gt;Style in it and you'll notice there are 4 other styles Excel creates by default:

 - Comma
 - Comma [0]
 - Currency
 - Currency [0]
 - Percent

I did a little digging and I was looking at the Perl module Spreadsheet::WriteExcel, which Spreadsheet_Excel_Writer is based on, and comparing the code it appears this was fixed in the Perl version since it was ported.

See http://search.cpan.org/src/JMCNAMARA/Spreadsheet-WriteExcel-2.20/lib/Spreadsheet/WriteExcel/Workbook.pm
lines 103-107 to see what I mean, though there are other areas that reference these new built-in styles.

I tried to fix this on my own, and got as far as having the styles included in the file so you didn't get an error, however I was never able to have them contain any actual style information (they were always using the Normal style).

Hope this info helps.

Test script:
---------------
No special script needed, as problem occurs with any spreadsheet generated by Spreadsheet_Excel_Writer</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by rweed
2008-02-21T12:59:37+00:00
PHP: 5.2.5 OS: Linux Package Version: CVS

Description:
------------
With any spreadsheet generated by Spreadsheet_Excel_Writer, if you open it in Excel and click the Currency, Comma, or Percent buttons in the toolbar, you're given the error &quot;Style 'Currency' not found.&quot; (obviously swap Currency for Comma/Percent where appropriate)

This is because the default formats are not being built into the file. To see what I mean, click Format-&gt;Style and notice that &quot;Normal&quot; is the only style in the dropdown. Use Excel to create a new workbook, and go to Format-&gt;Style in it and you'll notice there are 4 other styles Excel creates by default:

 - Comma
 - Comma [0]
 - Currency
 - Currency [0]
 - Percent

I did a little digging and I was looking at the Perl module Spreadsheet::WriteExcel, which Spreadsheet_Excel_Writer is based on, and comparing the code it appears this was fixed in the Perl version since it was ported.

See http://search.cpan.org/src/JMCNAMARA/Spreadsheet-WriteExcel-2.20/lib/Spreadsheet/WriteExcel/Workbook.pm
lines 103-107 to see what I mean, though there are other areas that reference these new built-in styles.

I tried to fix this on my own, and got as far as having the styles included in the file so you didn't get an error, however I was never able to have them contain any actual style information (they were always using the Normal style).

Hope this info helps.

Test script:
---------------
No special script needed, as problem occurs with any spreadsheet generated by Spreadsheet_Excel_Writer</pre>]]></description>
      <dc:date>2008-02-21T12:59:37+00:00</dc:date>
      <dc:creator>rweed &amp;#x61;&amp;#116; fundsforlearning &amp;#x64;&amp;#111;&amp;#x74; com</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/13149">
      <title>Spreadsheet_Excel_Writer: Bug 13149 [Open] repeatRows not working</title>
      <link>http://pear.php.net/bugs/13149</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by vkmeier
2008-02-19T10:30:56+00:00
PHP: Irrelevant OS: linux Package Version: 0.9.1

Description:
------------
I tried to use the repeatRows function in my code and it does not work when i run the file. Setting not set in the excel document. All other functions are working correctly for me. Even copied and pasted your example code and ran it and had the same resutls.

Test script:
---------------
$construction-&gt;write(7, 0,&quot;CELL TYPE&quot;,$yellow_bg);
$construction-&gt;write(7, 1,&quot;MONTH&quot;,$yellow_bg);
$construction-&gt;write(7, 2,&quot;SITE NAME&quot;,$yellow_bg);
$construction-&gt;repeatRows(7);

Expected result:
----------------
should repeat row 7 on the excel document. The setting should be automatically filled in under the page set up settings, it is left blank.

Actual result:
--------------
row 7 is not being repeated. The page set up settings are not being filled in.</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by vkmeier
2008-02-19T10:30:56+00:00
PHP: Irrelevant OS: linux Package Version: 0.9.1

Description:
------------
I tried to use the repeatRows function in my code and it does not work when i run the file. Setting not set in the excel document. All other functions are working correctly for me. Even copied and pasted your example code and ran it and had the same resutls.

Test script:
---------------
$construction-&gt;write(7, 0,&quot;CELL TYPE&quot;,$yellow_bg);
$construction-&gt;write(7, 1,&quot;MONTH&quot;,$yellow_bg);
$construction-&gt;write(7, 2,&quot;SITE NAME&quot;,$yellow_bg);
$construction-&gt;repeatRows(7);

Expected result:
----------------
should repeat row 7 on the excel document. The setting should be automatically filled in under the page set up settings, it is left blank.

Actual result:
--------------
row 7 is not being repeated. The page set up settings are not being filled in.</pre>]]></description>
      <dc:date>2008-02-19T10:30:56+00:00</dc:date>
      <dc:creator>victoria &amp;#x64;&amp;#111;&amp;#x74; meier &amp;#x61;&amp;#116; verizonwireless &amp;#x64;&amp;#111;&amp;#x74; com</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/12848">
      <title>Spreadsheet_Excel_Writer: Bug 12848 [Open] Excel &quot;File Error: data may have been lost.&quot;</title>
      <link>http://pear.php.net/bugs/12848</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by maartenba
2008-01-08T02:14:52+00:00
PHP: 5.2.4 OS: Any Package Version: CVS

Description:
------------
I tried using Spreadsheet_Excel_Writer to generate an XLS file, but when I open the file in Excel 2007 I first get the following alert box:

&quot;File Error: data may have been lost.&quot;

Note that this happens even for &quot;blank&quot; spreadsheets. After clicking &quot;OK&quot; I see no problems with the file, though.

The same behavior is seen in Excel 2003 Service Pack 3. Before upgrading Microsoft Office 2003 with service pack 3 there was no such problem.

Others seem to have similar problems with other packages (perhaps similar code)
http://groups.google.com/group/spreadsheet-writeexcel/browse_thread/thread/6656856820b6f799/

From what I read, the problem is that Excel 2007 is no longer compatible with Excel 95 spreadsheets, but only with Excel 97 spreadsheets and up. Same is the case for Excel 2003 with SP3.

Is there a workaround to this problem? I wouldn't mind sacrificing Excel 95 support.

Test script:
---------------
Examples:
* Trying with a workbook with a single blank worksheets gives error
* adding 1 non-empty cell fixes the error
* again, adding 1 extra blank worksheet makes error reappear</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by maartenba
2008-01-08T02:14:52+00:00
PHP: 5.2.4 OS: Any Package Version: CVS

Description:
------------
I tried using Spreadsheet_Excel_Writer to generate an XLS file, but when I open the file in Excel 2007 I first get the following alert box:

&quot;File Error: data may have been lost.&quot;

Note that this happens even for &quot;blank&quot; spreadsheets. After clicking &quot;OK&quot; I see no problems with the file, though.

The same behavior is seen in Excel 2003 Service Pack 3. Before upgrading Microsoft Office 2003 with service pack 3 there was no such problem.

Others seem to have similar problems with other packages (perhaps similar code)
http://groups.google.com/group/spreadsheet-writeexcel/browse_thread/thread/6656856820b6f799/

From what I read, the problem is that Excel 2007 is no longer compatible with Excel 95 spreadsheets, but only with Excel 97 spreadsheets and up. Same is the case for Excel 2003 with SP3.

Is there a workaround to this problem? I wouldn't mind sacrificing Excel 95 support.

Test script:
---------------
Examples:
* Trying with a workbook with a single blank worksheets gives error
* adding 1 non-empty cell fixes the error
* again, adding 1 extra blank worksheet makes error reappear</pre>]]></description>
      <dc:date>2008-01-08T07:35:08+00:00</dc:date>
      <dc:creator>pear &amp;#x61;&amp;#116; phpexcel &amp;#x64;&amp;#111;&amp;#x74; net</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/12684">
      <title>Spreadsheet_Excel_Writer: Feature/Change Request 12684 [Verified] addWorksheet() feature request</title>
      <link>http://pear.php.net/bugs/12684</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by wiesemann
2007-12-13T15:38:45+00:00
PHP: Irrelevant OS: Irrelevant Package Version: 

Manual page: package.fileformats.spreadsheet-excel-writer.spreadsheet-excel-writer-workbook.addworksheet.php

A nice feature to add would be to allow control over the position of the new worksheet, so something like:

//this would add a new worksheet as the first entry in the workbook
$sheet-&gt;addWorksheet(FIRST);

//this would add a new worksheet as the last entry in the workbook
$sheet-&gt;addWorksheet(LAST);

//this would add a new worksheet at position specified in the workbook
$sheet-&gt;addWorksheet(3);

default should be LAST, as it currently seems to be, and if you specify 3, but there is only 1, it should just be last.</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by wiesemann
2007-12-13T15:38:45+00:00
PHP: Irrelevant OS: Irrelevant Package Version: 

Manual page: package.fileformats.spreadsheet-excel-writer.spreadsheet-excel-writer-workbook.addworksheet.php

A nice feature to add would be to allow control over the position of the new worksheet, so something like:

//this would add a new worksheet as the first entry in the workbook
$sheet-&gt;addWorksheet(FIRST);

//this would add a new worksheet as the last entry in the workbook
$sheet-&gt;addWorksheet(LAST);

//this would add a new worksheet at position specified in the workbook
$sheet-&gt;addWorksheet(3);

default should be LAST, as it currently seems to be, and if you specify 3, but there is only 1, it should just be last.</pre>]]></description>
      <dc:date>2009-11-29T17:51:54+00:00</dc:date>
      <dc:creator>wiesemann &amp;#x61;&amp;#116; php &amp;#x64;&amp;#111;&amp;#x74; net</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Feature/Change Request</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/12629">
      <title>Spreadsheet_Excel_Writer: Bug 12629 [Verified] setVersion(8) crashes Excel 2000 w/ worksheets containing off-sheet references</title>
      <link>http://pear.php.net/bugs/12629</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by bishop
2007-12-06T11:23:34+00:00
PHP: Irrelevant OS: Irrelevant Package Version: 0.9.1

Description:
------------
Using off-sheet references in formulas, such as:
* ='SheetA'!A1
* ='Test Worksheet'!$B$12

causes Excel 2000 to crash (and OpenOffice to show #NAME?) when loading files written with BIFF 8.  On-sheet references work correctly with setVersion(8).

Test script:
---------------
// create the workbook
// NOTE: take out the setVersion() and everything works fine
require_once('Spreadsheet/Excel/Writer.php');
$workbook =&amp; new Spreadsheet_Excel_Writer($excelFilename);
$workbook-&gt;setVersion(8);

// add two sheets
// NOTE: order doesn't seem to matter -- in either order, crashes (Excel) or invalid references (OO) occur with setVersion(8) called
$sheetA =&amp; $workbook-&gt;addWorksheet('sheetA');
$sheetB =&amp; $workbook-&gt;addWorksheet('sheetB');

// put a value on sheet A, then reference that value on sheet B
// NOTE: Either of the writeFormula() crash Excel and yield #NAME? in OO with setVersion(8) called
$sheetA-&gt;write(0, 0, 'Hello, World!');
$sheetB-&gt;writeFormula(0, 0, &quot;='sheetA'!A1&quot;); // M$ Excel, canonical
$sheetB-&gt;writeFormula(0, 1, &quot;=sheetA!A1&quot;);   // M$ Excel

// finalize the file
$workbook-&gt;close();

Expected result:
----------------
The file specified by $excelFilename will contain an Excel workbook that can be opened in Excel 2000 without crash, then display &quot;Hello, World&quot; on Sheet A, A1 and Sheet B, A1 and A2.

Actual result:
--------------
Excel 2000 crashes, while OpenOffice displays #NAME? in all cells containing off-sheet references.</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by bishop
2007-12-06T11:23:34+00:00
PHP: Irrelevant OS: Irrelevant Package Version: 0.9.1

Description:
------------
Using off-sheet references in formulas, such as:
* ='SheetA'!A1
* ='Test Worksheet'!$B$12

causes Excel 2000 to crash (and OpenOffice to show #NAME?) when loading files written with BIFF 8.  On-sheet references work correctly with setVersion(8).

Test script:
---------------
// create the workbook
// NOTE: take out the setVersion() and everything works fine
require_once('Spreadsheet/Excel/Writer.php');
$workbook =&amp; new Spreadsheet_Excel_Writer($excelFilename);
$workbook-&gt;setVersion(8);

// add two sheets
// NOTE: order doesn't seem to matter -- in either order, crashes (Excel) or invalid references (OO) occur with setVersion(8) called
$sheetA =&amp; $workbook-&gt;addWorksheet('sheetA');
$sheetB =&amp; $workbook-&gt;addWorksheet('sheetB');

// put a value on sheet A, then reference that value on sheet B
// NOTE: Either of the writeFormula() crash Excel and yield #NAME? in OO with setVersion(8) called
$sheetA-&gt;write(0, 0, 'Hello, World!');
$sheetB-&gt;writeFormula(0, 0, &quot;='sheetA'!A1&quot;); // M$ Excel, canonical
$sheetB-&gt;writeFormula(0, 1, &quot;=sheetA!A1&quot;);   // M$ Excel

// finalize the file
$workbook-&gt;close();

Expected result:
----------------
The file specified by $excelFilename will contain an Excel workbook that can be opened in Excel 2000 without crash, then display &quot;Hello, World&quot; on Sheet A, A1 and Sheet B, A1 and A2.

Actual result:
--------------
Excel 2000 crashes, while OpenOffice displays #NAME? in all cells containing off-sheet references.</pre>]]></description>
      <dc:date>2008-03-22T23:15:21+00:00</dc:date>
      <dc:creator>php &amp;#x61;&amp;#116; ideacode &amp;#x64;&amp;#111;&amp;#x74; com</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/12362">
      <title>Spreadsheet_Excel_Writer: Bug 12362 [Open] named worksheets &amp; utf-8</title>
      <link>http://pear.php.net/bugs/12362</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by y2k
2007-10-30T16:13:51+00:00
PHP: 5.2.2 OS: win Package Version: 0.9.1

Description:
------------
Problem with named worksheets -- unable to use non-latin chars (garbage characters displayed instead), when using utf-8.

Test script:
---------------
$workbook = new Spreadsheet_Excel_Writer($file);
$workbook-&gt;setVersion(8);
$worksheet =&amp; $workbook-&gt;addWorksheet('Sheet &amp;#1051;&amp;#1080;&amp;#1089;&amp;#1090;');
$worksheet-&gt;setInputEncoding('UTF-8');
$worksheet-&gt;write(0, 0, 'Data &amp;#1044;&amp;#1072;&amp;#1085;&amp;#1085;&amp;#1099;&amp;#1077;');
$workbook-&gt;close();</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by y2k
2007-10-30T16:13:51+00:00
PHP: 5.2.2 OS: win Package Version: 0.9.1

Description:
------------
Problem with named worksheets -- unable to use non-latin chars (garbage characters displayed instead), when using utf-8.

Test script:
---------------
$workbook = new Spreadsheet_Excel_Writer($file);
$workbook-&gt;setVersion(8);
$worksheet =&amp; $workbook-&gt;addWorksheet('Sheet &amp;#1051;&amp;#1080;&amp;#1089;&amp;#1090;');
$worksheet-&gt;setInputEncoding('UTF-8');
$worksheet-&gt;write(0, 0, 'Data &amp;#1044;&amp;#1072;&amp;#1085;&amp;#1085;&amp;#1099;&amp;#1077;');
$workbook-&gt;close();</pre>]]></description>
      <dc:date>2007-11-02T16:16:49+00:00</dc:date>
      <dc:creator>y2k &amp;#x61;&amp;#116; hotbox &amp;#x64;&amp;#111;&amp;#x74; ru</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/12212">
      <title>Spreadsheet_Excel_Writer: Feature/Change Request 12212 [Verified] Auto Filtering</title>
      <link>http://pear.php.net/bugs/12212</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by xianve
2007-10-09T17:27:03+00:00
PHP: 5.2.4 OS: Linux Package Version: 0.9.1

Description:
------------
Would it be possible to add &quot;Auto Filter&quot; to the formats?

Test script:
---------------
void Format::setAutoFilter ()

Expected result:
----------------
When the document then renders, the AutoFilter'd cells will have the dropdown arrow.

Actual result:
--------------
Nothing right now.</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by xianve
2007-10-09T17:27:03+00:00
PHP: 5.2.4 OS: Linux Package Version: 0.9.1

Description:
------------
Would it be possible to add &quot;Auto Filter&quot; to the formats?

Test script:
---------------
void Format::setAutoFilter ()

Expected result:
----------------
When the document then renders, the AutoFilter'd cells will have the dropdown arrow.

Actual result:
--------------
Nothing right now.</pre>]]></description>
      <dc:date>2009-11-29T03:17:08+00:00</dc:date>
      <dc:creator>christian &amp;#x64;&amp;#111;&amp;#x74; van &amp;#x64;&amp;#111;&amp;#x74; eeden &amp;#x61;&amp;#116; schenker &amp;#x64;&amp;#111;&amp;#x74; ca</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Feature/Change Request</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/12109">
      <title>Spreadsheet_Excel_Writer: Bug 12109 [Open] Setting fgcolor to 47 actually sets it to 22</title>
      <link>http://pear.php.net/bugs/12109</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by gwinkless
2007-09-25T06:11:19+00:00
PHP: 4.3.2 OS: Linux Redhat 9 (Shrike) Package Version: 0.9.1

Description:
------------
As summary - setting fgcolor to 47 actually sets it to 22, as can be seen by the code below.

Test script:
---------------
&lt;?php

    require_once (&quot;Spreadsheet/Excel/Writer.php&quot;);
    $WB =&amp; new Spreadsheet_Excel_Writer();
    $sheet =&amp; $WB-&gt;addWorksheet();
    $sheet-&gt;write(0,0, &quot;color 47 - should be red, not green&quot;,  $WB-&gt;addFormat(array(&quot;fgcolor&quot;=&gt;&quot;47&quot;)));
    $WB-&gt;setCustomColor( 47, 255, 0, 0);
    $WB-&gt;setCustomColor( 22, 0, 255, 0);
    $WB-&gt;send(&quot;fgcolortest.xls&quot;);
    $WB-&gt;Close();

?&gt;

Expected result:
----------------
Should see a sheet with a single cell - 0,0 - with a red background.

Actual result:
--------------
Actually the background is green: the cell has been set to fgcolor index 22, not 47 as specified.</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by gwinkless
2007-09-25T06:11:19+00:00
PHP: 4.3.2 OS: Linux Redhat 9 (Shrike) Package Version: 0.9.1

Description:
------------
As summary - setting fgcolor to 47 actually sets it to 22, as can be seen by the code below.

Test script:
---------------
&lt;?php

    require_once (&quot;Spreadsheet/Excel/Writer.php&quot;);
    $WB =&amp; new Spreadsheet_Excel_Writer();
    $sheet =&amp; $WB-&gt;addWorksheet();
    $sheet-&gt;write(0,0, &quot;color 47 - should be red, not green&quot;,  $WB-&gt;addFormat(array(&quot;fgcolor&quot;=&gt;&quot;47&quot;)));
    $WB-&gt;setCustomColor( 47, 255, 0, 0);
    $WB-&gt;setCustomColor( 22, 0, 255, 0);
    $WB-&gt;send(&quot;fgcolortest.xls&quot;);
    $WB-&gt;Close();

?&gt;

Expected result:
----------------
Should see a sheet with a single cell - 0,0 - with a red background.

Actual result:
--------------
Actually the background is green: the cell has been set to fgcolor index 22, not 47 as specified.</pre>]]></description>
      <dc:date>2007-09-25T08:04:32+00:00</dc:date>
      <dc:creator>pear &amp;#x61;&amp;#116; geoff &amp;#x64;&amp;#111;&amp;#x74; dj</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/9879">
      <title>Spreadsheet_Excel_Writer: Feature/Change Request 9879 [Assigned] Worksheet::protect() shouldn't require a password.</title>
      <link>http://pear.php.net/bugs/9879</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by mikej@...
2007-01-19T10:45:58+00:00
PHP: 4.3.9 OS: Centos Linux 4.3 Package Version: 0.9.1

Description:
------------
I want to protect a worksheet to prevent accidental formula overwrites, but I don't really want to password protect it.  If I use Worksheet::protect(), I'm forced to give a password.  It would be nice if the password was optional.

Here is a replacement function:

function protect($password = NULL)
{
    $this-&gt;_protect   = 1;
    if ($password != NULL)
        $this-&gt;_password  = $this-&gt;_encodePassword($password);
}

I have worked around the problem for now by just setting the private member Worksheet::_protected to 1, but this is obviously not ideal.</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by mikej@...
2007-01-19T10:45:58+00:00
PHP: 4.3.9 OS: Centos Linux 4.3 Package Version: 0.9.1

Description:
------------
I want to protect a worksheet to prevent accidental formula overwrites, but I don't really want to password protect it.  If I use Worksheet::protect(), I'm forced to give a password.  It would be nice if the password was optional.

Here is a replacement function:

function protect($password = NULL)
{
    $this-&gt;_protect   = 1;
    if ($password != NULL)
        $this-&gt;_password  = $this-&gt;_encodePassword($password);
}

I have worked around the problem for now by just setting the private member Worksheet::_protected to 1, but this is obviously not ideal.</pre>]]></description>
      <dc:date>2009-11-29T03:07:10+00:00</dc:date>
      <dc:creator>mikej &amp;#x61;&amp;#116; primatech &amp;#x64;&amp;#111;&amp;#x74; com</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Feature/Change Request</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/9814">
      <title>Spreadsheet_Excel_Writer: Bug 9814 [Analyzed] writeFormula problem with HYPERLINK</title>
      <link>http://pear.php.net/bugs/9814</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by guillaume.lebigot@...
2007-01-12T11:55:47+00:00
PHP: 5.1.6 OS: WINDOWS Package Version: 

Description:
------------
Impossible to execute writeFormula to create an HYPERLINK through worksheets. (see my script)

Test script:
---------------
$Sai-&gt;writeFormula(0, 4, &quot;=HYPERLINK('sheet!A1','link')&quot;);

Expected result:
----------------
I expect to have my XLS generated with formulas in cells but when i call the generator script, my navigator crash with the use of this line. I have try a lot of possibilities.

help!

Actual result:
--------------
navigator crash</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by guillaume.lebigot@...
2007-01-12T11:55:47+00:00
PHP: 5.1.6 OS: WINDOWS Package Version: 

Description:
------------
Impossible to execute writeFormula to create an HYPERLINK through worksheets. (see my script)

Test script:
---------------
$Sai-&gt;writeFormula(0, 4, &quot;=HYPERLINK('sheet!A1','link')&quot;);

Expected result:
----------------
I expect to have my XLS generated with formulas in cells but when i call the generator script, my navigator crash with the use of this line. I have try a lot of possibilities.

help!

Actual result:
--------------
navigator crash</pre>]]></description>
      <dc:date>2009-08-11T10:34:52+00:00</dc:date>
      <dc:creator>guillaume &amp;#x64;&amp;#111;&amp;#x74; lebigot &amp;#x61;&amp;#116; gmail &amp;#x64;&amp;#111;&amp;#x74; com</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/9605">
      <title>Spreadsheet_Excel_Writer: Feature/Change Request 9605 [Open] Enhancement in external link handling</title>
      <link>http://pear.php.net/bugs/9605</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by dischinger@...
2006-12-13T09:11:20+00:00
PHP: Irrelevant OS: Irrelevant Package Version: 0.9.1

Description:
------------
File &quot;Worksheet.php&quot;, line 2023-2036

// Determine if the external link is relative or absolute:
//   relative if link contains no dir separator, &quot;somefile.xls&quot;
//   relative if link starts with up-dir, &quot;..\..\somefile.xls&quot;
//   otherwise, absolute

A relative external link starting from the current directory is not recognized as relative link, e.g. &quot;.\data\somefile.xls&quot;

Test script:
---------------
        // Determine if the link is relative or absolute:
        //   relative if link contains no dir separator, &quot;somefile.xls&quot;
        //   relative if link starts with up-dir, &quot;..\..\somefile.xls&quot;
ADDED   //   relative if link starts with acutal dir &quot;.\data\somefile.xls&quot; 
        //   otherwise, absolute
        
        $absolute    = 0x02; // Bit mask
        if (!preg_match(&quot;/\\\/&quot;, $url)) {
            $absolute    = 0x00;
        }
        if (preg_match(&quot;/^\.\.\\\/&quot;, $url)) {
            $absolute    = 0x00;
        }
ADDED   if (preg_match(&quot;/^\.\\\/&quot;, $url)) {
ADDED       $absolute    = 0x00;
ADDED   }</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by dischinger@...
2006-12-13T09:11:20+00:00
PHP: Irrelevant OS: Irrelevant Package Version: 0.9.1

Description:
------------
File &quot;Worksheet.php&quot;, line 2023-2036

// Determine if the external link is relative or absolute:
//   relative if link contains no dir separator, &quot;somefile.xls&quot;
//   relative if link starts with up-dir, &quot;..\..\somefile.xls&quot;
//   otherwise, absolute

A relative external link starting from the current directory is not recognized as relative link, e.g. &quot;.\data\somefile.xls&quot;

Test script:
---------------
        // Determine if the link is relative or absolute:
        //   relative if link contains no dir separator, &quot;somefile.xls&quot;
        //   relative if link starts with up-dir, &quot;..\..\somefile.xls&quot;
ADDED   //   relative if link starts with acutal dir &quot;.\data\somefile.xls&quot; 
        //   otherwise, absolute
        
        $absolute    = 0x02; // Bit mask
        if (!preg_match(&quot;/\\\/&quot;, $url)) {
            $absolute    = 0x00;
        }
        if (preg_match(&quot;/^\.\.\\\/&quot;, $url)) {
            $absolute    = 0x00;
        }
ADDED   if (preg_match(&quot;/^\.\\\/&quot;, $url)) {
ADDED       $absolute    = 0x00;
ADDED   }</pre>]]></description>
      <dc:date>2006-12-13T09:11:20+00:00</dc:date>
      <dc:creator>dischinger &amp;#x61;&amp;#116; vdi &amp;#x64;&amp;#111;&amp;#x74; de</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Feature/Change Request</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/9604">
      <title>Spreadsheet_Excel_Writer: Bug 9604 [Open] Error encountered with valid formula</title>
      <link>http://pear.php.net/bugs/9604</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by jas_khwong@...
2006-12-12T23:34:56+00:00
PHP: 5.0.5 OS: Linux Package Version: 0.9.1

Description:
------------
Spreadsheet_Excel_Writer outputs the following 
  Syntax error: , lookahead: , current char: 0
instead of the formula &quot;=$'sheet2'.$A$0&quot; which is a valid formula used for &quot;Paste Special-&gt;Links&quot; in Excel.




Test script:
---------------
&lt;?php
require_once &quot;Spreadsheet_Excel_Writer/writer.php&quot;;

$xls =&amp; new Spreadsheet_Excel_Writer();

$xls-&gt;send(&quot;test.xls&quot;);

$sheet1 =&amp; $xls-&gt;addWorksheet('sheet1');
$sheet2 =&amp; $xls-&gt;addWorksheet('sheet2');

$sheet1-&gt;write(0,0,&quot;100&quot;);
$sheet2-&gt;writeFormula(0,0,&quot;=\$'sheet1',\$A\$0&quot;);

$xls-&gt;close();
?&gt;</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by jas_khwong@...
2006-12-12T23:34:56+00:00
PHP: 5.0.5 OS: Linux Package Version: 0.9.1

Description:
------------
Spreadsheet_Excel_Writer outputs the following 
  Syntax error: , lookahead: , current char: 0
instead of the formula &quot;=$'sheet2'.$A$0&quot; which is a valid formula used for &quot;Paste Special-&gt;Links&quot; in Excel.




Test script:
---------------
&lt;?php
require_once &quot;Spreadsheet_Excel_Writer/writer.php&quot;;

$xls =&amp; new Spreadsheet_Excel_Writer();

$xls-&gt;send(&quot;test.xls&quot;);

$sheet1 =&amp; $xls-&gt;addWorksheet('sheet1');
$sheet2 =&amp; $xls-&gt;addWorksheet('sheet2');

$sheet1-&gt;write(0,0,&quot;100&quot;);
$sheet2-&gt;writeFormula(0,0,&quot;=\$'sheet1',\$A\$0&quot;);

$xls-&gt;close();
?&gt;</pre>]]></description>
      <dc:date>2006-12-12T23:34:56+00:00</dc:date>
      <dc:creator>jas_khwong &amp;#x61;&amp;#116; yahoo &amp;#x64;&amp;#111;&amp;#x74; com &amp;#x64;&amp;#111;&amp;#x74; sg</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/9533">
      <title>Spreadsheet_Excel_Writer: Bug 9533 [Open] mbstring.func_overload breaks Spreadsheet_Excel_Writer</title>
      <link>http://pear.php.net/bugs/9533</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by warrenklint@...
2006-12-04T04:59:30+00:00
PHP: 5.1.2 OS: Ubuntu Dapper LTS Package Version: 0.9.1

Description:
------------
Using php.ini's
 mbstring.func_overload = 7
breaks Spreadsheet_Excel_Writer</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by warrenklint@...
2006-12-04T04:59:30+00:00
PHP: 5.1.2 OS: Ubuntu Dapper LTS Package Version: 0.9.1

Description:
------------
Using php.ini's
 mbstring.func_overload = 7
breaks Spreadsheet_Excel_Writer</pre>]]></description>
      <dc:date>2006-12-19T10:57:46+00:00</dc:date>
      <dc:creator>warrenklint &amp;#x61;&amp;#116; gmail &amp;#x64;&amp;#111;&amp;#x74; com</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/9259">
      <title>Spreadsheet_Excel_Writer: Bug 9259 [Open] writeBlank not accepting formatting options</title>
      <link>http://pear.php.net/bugs/9259</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by trichard@...
2006-11-07T11:35:51+00:00
PHP: 5.1.4 OS: Fedora Core 5 Package Version: 0.9.1

Description:
------------
When using the writeBlank function with a formatting object the cell does not get formatted correctly.

Test script:
---------------
$rowLateCenterFormat =&amp; $xls-&gt;addFormat();
$rowLateCenterFormat-&gt;setLeft(1);
$rowLateCenterFormat-&gt;setRight(1);
$rowLateCenterFormat-&gt;setTextWrap();
$rowLateCenterFormat-&gt;setAlign('Top');
$rowLateCenterFormat-&gt;setAlign('Center');
$rowLateCenterFormat-&gt;setFgColor('43');
                                                $sheet-&gt;writeBlank(0, 0, $rowLateCenterFormat);


Expected result:
----------------
Would expect the cell the show up with a border on the left &amp; right, text align center, and the fg color set to a yellow.

Actual result:
--------------
Cell is not formatted at all.</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by trichard@...
2006-11-07T11:35:51+00:00
PHP: 5.1.4 OS: Fedora Core 5 Package Version: 0.9.1

Description:
------------
When using the writeBlank function with a formatting object the cell does not get formatted correctly.

Test script:
---------------
$rowLateCenterFormat =&amp; $xls-&gt;addFormat();
$rowLateCenterFormat-&gt;setLeft(1);
$rowLateCenterFormat-&gt;setRight(1);
$rowLateCenterFormat-&gt;setTextWrap();
$rowLateCenterFormat-&gt;setAlign('Top');
$rowLateCenterFormat-&gt;setAlign('Center');
$rowLateCenterFormat-&gt;setFgColor('43');
                                                $sheet-&gt;writeBlank(0, 0, $rowLateCenterFormat);


Expected result:
----------------
Would expect the cell the show up with a border on the left &amp; right, text align center, and the fg color set to a yellow.

Actual result:
--------------
Cell is not formatted at all.</pre>]]></description>
      <dc:date>2006-11-07T11:35:51+00:00</dc:date>
      <dc:creator>trichard &amp;#x61;&amp;#116; techovations &amp;#x64;&amp;#111;&amp;#x74; com</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/9126">
      <title>Spreadsheet_Excel_Writer: Bug 9126 [Open] SetVersion(8)-&gt;setInputEncoding('windows-1250') cells with many data,excelcrash</title>
      <link>http://pear.php.net/bugs/9126</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by dkozlows@...
2006-10-21T15:56:35+00:00
PHP: 4.3.10 OS: Windows Package Version: 0.9.1

Description:
------------
When I setup : 
SetVersion(8)
SetInputEncoding('windows-1250')
When I was add many cells with many data,excel was crashed.</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by dkozlows@...
2006-10-21T15:56:35+00:00
PHP: 4.3.10 OS: Windows Package Version: 0.9.1

Description:
------------
When I setup : 
SetVersion(8)
SetInputEncoding('windows-1250')
When I was add many cells with many data,excel was crashed.</pre>]]></description>
      <dc:date>2006-12-09T17:47:52+00:00</dc:date>
      <dc:creator>dkozlows &amp;#x61;&amp;#116; tlen &amp;#x64;&amp;#111;&amp;#x74; pl</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/9062">
      <title>Spreadsheet_Excel_Writer: Bug 9062 [Verified] Euro does not appear correctly in formula styles</title>
      <link>http://pear.php.net/bugs/9062</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by simon@...
2006-10-16T08:03:24+00:00
PHP: 4.4.3 OS: Apache Webserver | Windows XL Package Version: 0.9.1

Description:
------------
I can add the euro symbol to a worksheet as text field with no problem but when i use the euro symbol as part of a number format in a style the euro is encoded incorrectly.

From past experience the Euro symobl may not appear correctly in this bug report, 

setNumFormat(&quot;#,##0.00 Â¤&quot;);

The character between the 0.00 and the close quote should be a euro symbol

Test script:
---------------
&lt;?
include(&quot;Spreadsheet/Excel/Writer.php&quot;);
$workbook = new Spreadsheet_Excel_Writer();
$workbook-&gt;setVersion(8);
$worksheet =&amp; $workbook-&gt;addWorksheet();
$worksheet-&gt;setInputEncoding('UTF-8');

$CurrencyStyle =&amp; $workbook-&gt;addFormat();
$CurrencyStyle-&gt;setNumFormat(&quot;#,##0.00 Â¤&quot;);

/** this one works ok when added as text */
$worksheet-&gt;write(0,0,&quot;2.15 Â¤&quot;);

/** because the euro is added as a format, it now fails */
$worksheet-&gt;write(1,1,&quot;2.15&quot;,$CurrencyStyle);

$workbook-&gt;send('Euro.xls');
$workbook-&gt;close();
?&gt;

Expected result:
----------------
Euro should display correctly in the sheet regardless if it is a format or a text.</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by simon@...
2006-10-16T08:03:24+00:00
PHP: 4.4.3 OS: Apache Webserver | Windows XL Package Version: 0.9.1

Description:
------------
I can add the euro symbol to a worksheet as text field with no problem but when i use the euro symbol as part of a number format in a style the euro is encoded incorrectly.

From past experience the Euro symobl may not appear correctly in this bug report, 

setNumFormat(&quot;#,##0.00 Â¤&quot;);

The character between the 0.00 and the close quote should be a euro symbol

Test script:
---------------
&lt;?
include(&quot;Spreadsheet/Excel/Writer.php&quot;);
$workbook = new Spreadsheet_Excel_Writer();
$workbook-&gt;setVersion(8);
$worksheet =&amp; $workbook-&gt;addWorksheet();
$worksheet-&gt;setInputEncoding('UTF-8');

$CurrencyStyle =&amp; $workbook-&gt;addFormat();
$CurrencyStyle-&gt;setNumFormat(&quot;#,##0.00 Â¤&quot;);

/** this one works ok when added as text */
$worksheet-&gt;write(0,0,&quot;2.15 Â¤&quot;);

/** because the euro is added as a format, it now fails */
$worksheet-&gt;write(1,1,&quot;2.15&quot;,$CurrencyStyle);

$workbook-&gt;send('Euro.xls');
$workbook-&gt;close();
?&gt;

Expected result:
----------------
Euro should display correctly in the sheet regardless if it is a format or a text.</pre>]]></description>
      <dc:date>2009-08-05T13:41:38+00:00</dc:date>
      <dc:creator>simon &amp;#x61;&amp;#116; elroble &amp;#x64;&amp;#111;&amp;#x74; co &amp;#x64;&amp;#111;&amp;#x74; uk</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/8967">
      <title>Spreadsheet_Excel_Writer: Bug 8967 [Open] Excel XP crashes when generated worksheet have many cell merges</title>
      <link>http://pear.php.net/bugs/8967</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by paladin80@...
2006-10-11T07:53:29+00:00
PHP: 5.0.4 OS: win XP Package Version: 0.9.1

Description:
------------
Excel XP crashes when generated worsheet have many column merges. 
Merges are become bugous when spreadsheet have about 400 of them. When count of merges is more than 700, Excel XP crushes.

Test script:
---------------
&lt;?php
include_once &quot;Spreadsheet/Excel/Writer.php&quot;; 
$xls =&amp; new Spreadsheet_Excel_Writer(); 
$xls-&gt;send(&quot;table.xls&quot;); 
$sheet =&amp; $xls-&gt;addWorksheet('table');
for($i=0; $i&lt;40; $i++){//change to $i&lt;100 to get excel crush
	for($j=0;$j&lt;20;$j+=2){
    	$sheet-&gt;setMerge($i, $j, $i, $j+1);
    }
}
$xls-&gt;close();
?&gt;

Expected result:
----------------
A blank table, each cell must have colspan=2 and rowspan=1.

Actual result:
--------------
A blank table, each cell have colspan=2, but many cells from column &quot;M&quot; have rowspan=2.

When I extend the table up to 100 rows, I get the excel crush.</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by paladin80@...
2006-10-11T07:53:29+00:00
PHP: 5.0.4 OS: win XP Package Version: 0.9.1

Description:
------------
Excel XP crashes when generated worsheet have many column merges. 
Merges are become bugous when spreadsheet have about 400 of them. When count of merges is more than 700, Excel XP crushes.

Test script:
---------------
&lt;?php
include_once &quot;Spreadsheet/Excel/Writer.php&quot;; 
$xls =&amp; new Spreadsheet_Excel_Writer(); 
$xls-&gt;send(&quot;table.xls&quot;); 
$sheet =&amp; $xls-&gt;addWorksheet('table');
for($i=0; $i&lt;40; $i++){//change to $i&lt;100 to get excel crush
	for($j=0;$j&lt;20;$j+=2){
    	$sheet-&gt;setMerge($i, $j, $i, $j+1);
    }
}
$xls-&gt;close();
?&gt;

Expected result:
----------------
A blank table, each cell must have colspan=2 and rowspan=1.

Actual result:
--------------
A blank table, each cell have colspan=2, but many cells from column &quot;M&quot; have rowspan=2.

When I extend the table up to 100 rows, I get the excel crush.</pre>]]></description>
      <dc:date>2006-10-13T07:25:36+00:00</dc:date>
      <dc:creator>paladin80 &amp;#x61;&amp;#116; gmail &amp;#x64;&amp;#111;&amp;#x74; com</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/8733">
      <title>Spreadsheet_Excel_Writer: Bug 8733 [Open] *** ERROR IN SST ***</title>
      <link>http://pear.php.net/bugs/8733</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by zielony@...
2006-09-19T04:35:31+00:00
PHP: Irrelevant OS: Linux Package Version: 0.9.0

Description:
------------
Error in Shared Strings Table when using setVersion(8).

Test script:
---------------
function GenerateRandomString( $i )
{
    return md5( $i );
};

$workbook=new Spreadsheet_Excel_Writer_Workbook(&quot;&quot;);
$workbook-&gt;setVersion(8);
$worksheet =&amp; $workbook-&gt;addWorksheet('worksheet');
$worksheet-&gt;setInputEncoding('utf-8');

for( $i=1; $i&lt;2000; $i++ )
{
    $worksheet-&gt;write($i, 0, $i );
    $worksheet-&gt;write($i, 1, GenerateRandomString($i) );
};

$workbook-&gt;close();</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by zielony@...
2006-09-19T04:35:31+00:00
PHP: Irrelevant OS: Linux Package Version: 0.9.0

Description:
------------
Error in Shared Strings Table when using setVersion(8).

Test script:
---------------
function GenerateRandomString( $i )
{
    return md5( $i );
};

$workbook=new Spreadsheet_Excel_Writer_Workbook(&quot;&quot;);
$workbook-&gt;setVersion(8);
$worksheet =&amp; $workbook-&gt;addWorksheet('worksheet');
$worksheet-&gt;setInputEncoding('utf-8');

for( $i=1; $i&lt;2000; $i++ )
{
    $worksheet-&gt;write($i, 0, $i );
    $worksheet-&gt;write($i, 1, GenerateRandomString($i) );
};

$workbook-&gt;close();</pre>]]></description>
      <dc:date>2006-09-20T05:57:20+00:00</dc:date>
      <dc:creator>zielony &amp;#x61;&amp;#116; gemius &amp;#x64;&amp;#111;&amp;#x74; pl</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/8601">
      <title>Spreadsheet_Excel_Writer: Bug 8601 [Verified] setNumFormat() for numbers stored as text doesn't work for numbers.</title>
      <link>http://pear.php.net/bugs/8601</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by wizard@...
2006-08-31T14:45:06+00:00
PHP: 5.2.0 RC2 OS: windows 2000/xp Package Version: 0.9.2

Description:
------------
$textFormat-&gt;setNumFormat('@') or
$textFormat-&gt;setNumFormat(49) doesn't work for formatting data as text (such as numbers that you want stored as text). I referred to open office document for the excel file format (page 160) for the @ and the 49 that should refer to formatting as text. So numbers starting with zero loose their zeros and long numbers show as scientific notation.

Test script:
---------------
&lt;?php
    require_once &quot;Spreadsheet/Excel/Writer.php&quot;; 
    $workbook =&amp; new Spreadsheet_Excel_Writer();
    $workbook-&gt;send('test.xls');
    $textFormat =&amp; $workbook-&gt;addFormat();
    $textFormat-&gt;setNumFormat('@'); //or 49
    $sheet1 =&amp; $workbook-&gt;addWorksheet('Not my first sheet');
    $sheet1-&gt;setColumn(0,0,20,$textFormat);
    $sheet1-&gt;write(0,0,&quot;000034534&quot;);
    $sheet1-&gt;write(1,0,&quot;100000298109&quot;);
    $sheet1-&gt;write(2,0,&quot;00324838284&quot;);
    $sheet1-&gt;write(3,0,&quot;00456744675454654556&quot;);
    $workbook-&gt;close();
?&gt;

Expected result:
----------------
000034534
100000298109
00324838284
00456744675454654556

Actual result:
--------------
34534
1E+11
324838284
4.56745E+17</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by wizard@...
2006-08-31T14:45:06+00:00
PHP: 5.2.0 RC2 OS: windows 2000/xp Package Version: 0.9.2

Description:
------------
$textFormat-&gt;setNumFormat('@') or
$textFormat-&gt;setNumFormat(49) doesn't work for formatting data as text (such as numbers that you want stored as text). I referred to open office document for the excel file format (page 160) for the @ and the 49 that should refer to formatting as text. So numbers starting with zero loose their zeros and long numbers show as scientific notation.

Test script:
---------------
&lt;?php
    require_once &quot;Spreadsheet/Excel/Writer.php&quot;; 
    $workbook =&amp; new Spreadsheet_Excel_Writer();
    $workbook-&gt;send('test.xls');
    $textFormat =&amp; $workbook-&gt;addFormat();
    $textFormat-&gt;setNumFormat('@'); //or 49
    $sheet1 =&amp; $workbook-&gt;addWorksheet('Not my first sheet');
    $sheet1-&gt;setColumn(0,0,20,$textFormat);
    $sheet1-&gt;write(0,0,&quot;000034534&quot;);
    $sheet1-&gt;write(1,0,&quot;100000298109&quot;);
    $sheet1-&gt;write(2,0,&quot;00324838284&quot;);
    $sheet1-&gt;write(3,0,&quot;00456744675454654556&quot;);
    $workbook-&gt;close();
?&gt;

Expected result:
----------------
000034534
100000298109
00324838284
00456744675454654556

Actual result:
--------------
34534
1E+11
324838284
4.56745E+17</pre>]]></description>
      <dc:date>2009-11-29T00:46:38+00:00</dc:date>
      <dc:creator>wizard &amp;#x61;&amp;#116; roborooter &amp;#x64;&amp;#111;&amp;#x74; com</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/8323">
      <title>Spreadsheet_Excel_Writer: Bug 8323 [Open] setNumFormat Ignored</title>
      <link>http://pear.php.net/bugs/8323</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by 20060106@...
2006-07-30T00:33:04+00:00
PHP: 4.3.11 OS: Linux Package Version: 0.9.0

Description:
------------
I want to format a particular column as text, as opposed to general.

I tried the following, where 9 should correspond to the text cell format, but I guess there's a problem in the module itself, as it is still formatted as general.

Re. bug #3514: this appears related but distinct in that my understanding is that setNumFormat should take an integer corresponding to a particular cell format.

Test script:
---------------
$date_format =&amp; $workbook-&gt;addFormat();
$date_format-&gt;setNumFormat(9);
$worksheet-&gt;setColumn(3,3,12,$date_format);

Expected result:
----------------
The third column should be formatted as type text (9).

Actual result:
--------------
The third column is formatted as type general (0).</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by 20060106@...
2006-07-30T00:33:04+00:00
PHP: 4.3.11 OS: Linux Package Version: 0.9.0

Description:
------------
I want to format a particular column as text, as opposed to general.

I tried the following, where 9 should correspond to the text cell format, but I guess there's a problem in the module itself, as it is still formatted as general.

Re. bug #3514: this appears related but distinct in that my understanding is that setNumFormat should take an integer corresponding to a particular cell format.

Test script:
---------------
$date_format =&amp; $workbook-&gt;addFormat();
$date_format-&gt;setNumFormat(9);
$worksheet-&gt;setColumn(3,3,12,$date_format);

Expected result:
----------------
The third column should be formatted as type text (9).

Actual result:
--------------
The third column is formatted as type general (0).</pre>]]></description>
      <dc:date>2006-07-30T00:33:04+00:00</dc:date>
      <dc:creator>20060106 &amp;#x61;&amp;#116; ausbdm &amp;#x64;&amp;#111;&amp;#x74; org</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/8303">
      <title>Spreadsheet_Excel_Writer: Feature/Change Request 8303 [Verified] Support for auto sizing of columns</title>
      <link>http://pear.php.net/bugs/8303</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by dsanders@...
2006-07-27T01:57:22+00:00
PHP: 4.3.10 OS: FC2 Package Version: 0.9.0

Description:
------------
It'd be great to add support for auto sizing of the column widths... I've attempted to create my own patch for this, but I don't fully understand how this package stores the cell information so I guess you guys could do a better job.

A possible simple patch for this would be in Worksheet.php. (see test script)

This patch assumes that 1 unit of width is about the same as the width of 1 character at size 10 Arial.  It's not accurate, but it gives me satisfactory sizing of the columns.

Test script:
---------------
@@ -497,6 +497,12 @@ class Spreadsheet_Excel_Writer_Worksheet
     {
         $num_sheets = count($sheetnames);
 
+        // set the column widths, if we need to
+        if (!empty($this-&gt;col_auto_width))
+        {
+            $this-&gt;_setColumnAutoWidths();
+        }
+
         /***********************************************
         * Prepend in reverse order!!
         */
@@ -740,6 +746,44 @@ class Spreadsheet_Excel_Writer_Worksheet
         }
     }
 
+    var $col_auto_width_padding = array();
+    var $col_widths = array();
+    var $col_auto_width = array();
+    /**
+    * 
+    * @access public
+    * @param integer $firstcol first column on the range
+    * @param integer $lastcol  last column on the range
+    * @param bool    $flag     turn on/off the auto-width
+    * @param integer $padding  amount of padding to add to the column width
+    */
+    function setColumnAutoWidth($firstcol, $lastcol, $flag = true, $padding = 0)
+    {
+        for ($col = $firstcol; $col &lt;= $lastcol; $col++)
+        { 
+            if ($flag)
+            {
+                $this-&gt;col_auto_width[$col] = $flag;
+            }
+            else
+            {
+                unset($this-&gt;col_auto_width[$col]);
+            }
+            $this-&gt;col_auto_width_padding[$col] = $padding;
+        }
+    }
+
+    function _setColumnAutoWidths()
+    {
+        foreach ($this-&gt;col_auto_width as $col =&gt; $something)
+        {
+            if (isset($this-&gt;col_widths[$col]))
+            {
+                $this-&gt;setColumn($col,$col,$this-&gt;col_widths[$col] + $this-&gt;col_auto_width_padding[$col]);
+            }
+        }
+    }
+
     /**
     * Set which cell or cells are selected in a worksheet
     *
@@ -1410,6 +1454,16 @@ class Spreadsheet_Excel_Writer_Worksheet
     */
     function writeNumber($row, $col, $num, $format = 0)
     {
+        // record the number of digits, if we are auto column sizing
+        if (!empty($this-&gt;col_auto_width[$col]))
+        {
+            $length = strlen($num);
+            if (empty($this-&gt;col_widths[$col]) || $length  &gt; $this-&gt;col_widths[$col])
+            {
+                $this-&gt;col_widths[$col] = $length;
+            }
+        }
+ 
         $record    = 0x0203;                 // Record identifier
         $length    = 0x000E;                 // Number of bytes to follow
 
@@ -1463,6 +1517,17 @@ class Spreadsheet_Excel_Writer_Worksheet
     */
     function writeString($row, $col, $str, $format = 0)
     {
+        // record the string length, if using auto column sizing
+        if (!empty($this-&gt;col_auto_width[$col]))
+        {
+            $length = strlen($str);
+
+            if (empty($this-&gt;col_widths[$col]) || $length  &gt; $this-&gt;col_widths[$col])
+            {
+                $this-&gt;col_widths[$col] = $length;
+            }
+        }
+ 
         if ($this-&gt;_BIFF_version == 0x0600) {
             return $this-&gt;writeStringBIFF8($row, $col, $str, $format);
         }
@@ -1813,6 +1878,16 @@ class Spreadsheet_Excel_Writer_Worksheet
     */
     function writeUrl($row, $col, $url, $string = '', $format = 0)
     {
+        // record the string length, if using auto column sizing
+        if (!empty($this-&gt;col_auto_width[$col]))
+        {
+            $length = strlen($url);
+            if (empty($this-&gt;col_widths[$col]) || $length  &gt; $this-&gt;col_widths[$col])
+            {
+                $this-&gt;col_widths[$col] = $length;
+            }
+        }
+ 
         // Add start row and col to arg list
         return($this-&gt;_writeUrlRange($row, $col, $row, $col, $url, $string, $format));
     }</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by dsanders@...
2006-07-27T01:57:22+00:00
PHP: 4.3.10 OS: FC2 Package Version: 0.9.0

Description:
------------
It'd be great to add support for auto sizing of the column widths... I've attempted to create my own patch for this, but I don't fully understand how this package stores the cell information so I guess you guys could do a better job.

A possible simple patch for this would be in Worksheet.php. (see test script)

This patch assumes that 1 unit of width is about the same as the width of 1 character at size 10 Arial.  It's not accurate, but it gives me satisfactory sizing of the columns.

Test script:
---------------
@@ -497,6 +497,12 @@ class Spreadsheet_Excel_Writer_Worksheet
     {
         $num_sheets = count($sheetnames);
 
+        // set the column widths, if we need to
+        if (!empty($this-&gt;col_auto_width))
+        {
+            $this-&gt;_setColumnAutoWidths();
+        }
+
         /***********************************************
         * Prepend in reverse order!!
         */
@@ -740,6 +746,44 @@ class Spreadsheet_Excel_Writer_Worksheet
         }
     }
 
+    var $col_auto_width_padding = array();
+    var $col_widths = array();
+    var $col_auto_width = array();
+    /**
+    * 
+    * @access public
+    * @param integer $firstcol first column on the range
+    * @param integer $lastcol  last column on the range
+    * @param bool    $flag     turn on/off the auto-width
+    * @param integer $padding  amount of padding to add to the column width
+    */
+    function setColumnAutoWidth($firstcol, $lastcol, $flag = true, $padding = 0)
+    {
+        for ($col = $firstcol; $col &lt;= $lastcol; $col++)
+        { 
+            if ($flag)
+            {
+                $this-&gt;col_auto_width[$col] = $flag;
+            }
+            else
+            {
+                unset($this-&gt;col_auto_width[$col]);
+            }
+            $this-&gt;col_auto_width_padding[$col] = $padding;
+        }
+    }
+
+    function _setColumnAutoWidths()
+    {
+        foreach ($this-&gt;col_auto_width as $col =&gt; $something)
+        {
+            if (isset($this-&gt;col_widths[$col]))
+            {
+                $this-&gt;setColumn($col,$col,$this-&gt;col_widths[$col] + $this-&gt;col_auto_width_padding[$col]);
+            }
+        }
+    }
+
     /**
     * Set which cell or cells are selected in a worksheet
     *
@@ -1410,6 +1454,16 @@ class Spreadsheet_Excel_Writer_Worksheet
     */
     function writeNumber($row, $col, $num, $format = 0)
     {
+        // record the number of digits, if we are auto column sizing
+        if (!empty($this-&gt;col_auto_width[$col]))
+        {
+            $length = strlen($num);
+            if (empty($this-&gt;col_widths[$col]) || $length  &gt; $this-&gt;col_widths[$col])
+            {
+                $this-&gt;col_widths[$col] = $length;
+            }
+        }
+ 
         $record    = 0x0203;                 // Record identifier
         $length    = 0x000E;                 // Number of bytes to follow
 
@@ -1463,6 +1517,17 @@ class Spreadsheet_Excel_Writer_Worksheet
     */
     function writeString($row, $col, $str, $format = 0)
     {
+        // record the string length, if using auto column sizing
+        if (!empty($this-&gt;col_auto_width[$col]))
+        {
+            $length = strlen($str);
+
+            if (empty($this-&gt;col_widths[$col]) || $length  &gt; $this-&gt;col_widths[$col])
+            {
+                $this-&gt;col_widths[$col] = $length;
+            }
+        }
+ 
         if ($this-&gt;_BIFF_version == 0x0600) {
             return $this-&gt;writeStringBIFF8($row, $col, $str, $format);
         }
@@ -1813,6 +1878,16 @@ class Spreadsheet_Excel_Writer_Worksheet
     */
     function writeUrl($row, $col, $url, $string = '', $format = 0)
     {
+        // record the string length, if using auto column sizing
+        if (!empty($this-&gt;col_auto_width[$col]))
+        {
+            $length = strlen($url);
+            if (empty($this-&gt;col_widths[$col]) || $length  &gt; $this-&gt;col_widths[$col])
+            {
+                $this-&gt;col_widths[$col] = $length;
+            }
+        }
+ 
         // Add start row and col to arg list
         return($this-&gt;_writeUrlRange($row, $col, $row, $col, $url, $string, $format));
     }</pre>]]></description>
      <dc:date>2009-11-29T03:09:05+00:00</dc:date>
      <dc:creator>dsanders &amp;#x61;&amp;#116; baselinesolutions &amp;#x64;&amp;#111;&amp;#x74; com &amp;#x64;&amp;#111;&amp;#x74; au</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Feature/Change Request</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/7672">
      <title>Spreadsheet_Excel_Writer: Feature/Change Request 7672 [Verified] Page Order</title>
      <link>http://pear.php.net/bugs/7672</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by jhoar@...
2006-05-19T12:26:49+00:00
PHP: 5.1.2 OS: SUSE Linux Enterprise 10 Package Version: 0.9.0

Description:
------------
It would be a very useful feature to be able to set the Page Order for printing (in Excel under &quot;Page Setup &gt; Sheet&quot;). Excel's default is &quot;Down, then over&quot; and I want &quot;Over, then down&quot;.</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by jhoar@...
2006-05-19T12:26:49+00:00
PHP: 5.1.2 OS: SUSE Linux Enterprise 10 Package Version: 0.9.0

Description:
------------
It would be a very useful feature to be able to set the Page Order for printing (in Excel under &quot;Page Setup &gt; Sheet&quot;). Excel's default is &quot;Down, then over&quot; and I want &quot;Over, then down&quot;.</pre>]]></description>
      <dc:date>2009-11-29T03:04:15+00:00</dc:date>
      <dc:creator>jhoar &amp;#x61;&amp;#116; bjservices &amp;#x64;&amp;#111;&amp;#x74; ca</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Feature/Change Request</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/7504">
      <title>Spreadsheet_Excel_Writer: Bug 7504 [Verified] Formulas problems</title>
      <link>http://pear.php.net/bugs/7504</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by admin@...
2006-04-27T09:49:24+00:00
PHP: 5.1.0 OS: FEDORA core 4 Package Version: 0.9.0

Description:
------------
Before starting, many thanks to the team for this very useful package.

I want to insert the following formula :
=AVERAGE(IF(C35:F35&lt;&gt;0;C35:F35))

When I open the xls file I get an error : &quot;VALUE!&quot;

But if I manually modify the formula (just erase the bracket and insert it again) and press SHIFT-CTRL-ENTER, everything is ok.

So the syntax of the formula is ok but Excel does not recognize this array formula.</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by admin@...
2006-04-27T09:49:24+00:00
PHP: 5.1.0 OS: FEDORA core 4 Package Version: 0.9.0

Description:
------------
Before starting, many thanks to the team for this very useful package.

I want to insert the following formula :
=AVERAGE(IF(C35:F35&lt;&gt;0;C35:F35))

When I open the xls file I get an error : &quot;VALUE!&quot;

But if I manually modify the formula (just erase the bracket and insert it again) and press SHIFT-CTRL-ENTER, everything is ok.

So the syntax of the formula is ok but Excel does not recognize this array formula.</pre>]]></description>
      <dc:date>2006-10-06T03:04:37+00:00</dc:date>
      <dc:creator>admin &amp;#x61;&amp;#116; confort-it &amp;#x64;&amp;#111;&amp;#x74; com</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/5560">
      <title>Spreadsheet_Excel_Writer: Feature/Change Request 5560 [Verified] Add Autofilter Functionality</title>
      <link>http://pear.php.net/bugs/5560</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by pear@...
2005-09-29T08:51:20+00:00
PHP: Irrelevant OS:  Package Version: 

Description:
------------
I'm surprised that this has not been requested before:

The ability to enable AutoFilter on a particular row/particular cells would be extremely useful.</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by pear@...
2005-09-29T08:51:20+00:00
PHP: Irrelevant OS:  Package Version: 

Description:
------------
I'm surprised that this has not been requested before:

The ability to enable AutoFilter on a particular row/particular cells would be extremely useful.</pre>]]></description>
      <dc:date>2009-11-29T02:48:04+00:00</dc:date>
      <dc:creator>pear &amp;#x61;&amp;#116; matosconsulting &amp;#x64;&amp;#111;&amp;#x74; com</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Feature/Change Request</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/5347">
      <title>Spreadsheet_Excel_Writer: Bug 5347 [Analyzed] using writeNote() causes excel crash</title>
      <link>http://pear.php.net/bugs/5347</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by patrick.douret@...
2005-09-09T04:39:55+00:00
PHP: 4.3.3 OS: Windows 2000 Professionnal Package Version: 

Description:
------------
I need to create an excel sheet in which I would like to add notes for some cells.

So I am using the function writeNote.
When opening the xls document, excel crashes.


My version are:
PHP 4.3.3
EXCEL 2000 SR1 (FRENCH)
Spreadsheet_Excel_Writer-0.8
OLE-0.5

Test script:
---------------
&lt;?php
require_once('php/v1_1/classes/Excel/pear/Worksheet.php');
require_once('php/v1_1/classes/Excel/pear/Workbook.php');

$fname     = tempnam(&quot;./tmp&quot;, &quot;laf.xls&quot;);

$workbook  =&amp; new Spreadsheet_Excel_Writer_Workbook($fname);
$workbook-&gt;setVersion(8);  //I need this for some reasons
$worksheet =&amp; $workbook-&gt;addworksheet('test');

$worksheet-&gt;writeString( 5, 1, &quot;ceci n'est qu'un test totalement bidon&quot;, $fTxtCell_2);
$worksheet-&gt;writeNote( 5, 1, &quot;ceci n'est qu'un test  de note totalement bidon&quot;);
$workbook-&gt;close();
?&gt;


Expected result:
----------------
The created xls document should open correctly.
The cell (5,1) should contain &quot;ceci n'est qu'un test totalement bidon&quot; and it's associated note should be &quot;ceci n'est qu'un test  de note totalement bidon&quot;.

Actual result:
--------------
I've got a lovely message box saying that memory cannot be read and excel will be closed</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by patrick.douret@...
2005-09-09T04:39:55+00:00
PHP: 4.3.3 OS: Windows 2000 Professionnal Package Version: 

Description:
------------
I need to create an excel sheet in which I would like to add notes for some cells.

So I am using the function writeNote.
When opening the xls document, excel crashes.


My version are:
PHP 4.3.3
EXCEL 2000 SR1 (FRENCH)
Spreadsheet_Excel_Writer-0.8
OLE-0.5

Test script:
---------------
&lt;?php
require_once('php/v1_1/classes/Excel/pear/Worksheet.php');
require_once('php/v1_1/classes/Excel/pear/Workbook.php');

$fname     = tempnam(&quot;./tmp&quot;, &quot;laf.xls&quot;);

$workbook  =&amp; new Spreadsheet_Excel_Writer_Workbook($fname);
$workbook-&gt;setVersion(8);  //I need this for some reasons
$worksheet =&amp; $workbook-&gt;addworksheet('test');

$worksheet-&gt;writeString( 5, 1, &quot;ceci n'est qu'un test totalement bidon&quot;, $fTxtCell_2);
$worksheet-&gt;writeNote( 5, 1, &quot;ceci n'est qu'un test  de note totalement bidon&quot;);
$workbook-&gt;close();
?&gt;


Expected result:
----------------
The created xls document should open correctly.
The cell (5,1) should contain &quot;ceci n'est qu'un test totalement bidon&quot; and it's associated note should be &quot;ceci n'est qu'un test  de note totalement bidon&quot;.

Actual result:
--------------
I've got a lovely message box saying that memory cannot be read and excel will be closed</pre>]]></description>
      <dc:date>2009-08-12T07:49:13+00:00</dc:date>
      <dc:creator>patrick &amp;#x64;&amp;#111;&amp;#x74; douret &amp;#x61;&amp;#116; edf &amp;#x64;&amp;#111;&amp;#x74; fr</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/4665">
      <title>Spreadsheet_Excel_Writer: Feature/Change Request 4665 [Verified] Support for extended classes</title>
      <link>http://pear.php.net/bugs/4665</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by dan@...
2005-06-23T02:38:57+00:00
PHP: Irrelevant OS:  Package Version: 

Description:
------------
Now when extending Spreadsheet_Excel_Writer_Workbook class there is no way to return extended classes for *_Worksheet, *_Format, etc. from -&gt;addWorksheet(), -&gt;addFormat(), etc...

I sudgest to add additional parameter for those methods - $className:

&lt; function &amp;addWorksheet($name = '')
&gt; function &amp;addWorksheet($name = '', $className = '')

&lt; function &amp;addFormat($properties = array())
&gt; function &amp;addFormat($properties = array(), $className = '')

...

And then reimplement thouse methods to support different classes:

&lt; $worksheet = new Spreadsheet_Excel_Writer_Worksheet(...

&gt; if (! class_exists($className)) {
&gt;     $className = 'Spreadsheet_Excel_Writer_Worksheet';
&gt; }
&gt; $worksheet = new $className(...
&gt; if (! is_a($worksheet, 'Spreadsheet_Excel_Writer_Worksheet')) {
&gt;     $this-&gt;raiseError('Custom class do not extends Spreadsheet_Excel_Writer_Worksheet', 0, PEAR_ERROR_DIE);
&gt; }

...and the same for all other classes.</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Feature/Change Request
Reported by dan@...
2005-06-23T02:38:57+00:00
PHP: Irrelevant OS:  Package Version: 

Description:
------------
Now when extending Spreadsheet_Excel_Writer_Workbook class there is no way to return extended classes for *_Worksheet, *_Format, etc. from -&gt;addWorksheet(), -&gt;addFormat(), etc...

I sudgest to add additional parameter for those methods - $className:

&lt; function &amp;addWorksheet($name = '')
&gt; function &amp;addWorksheet($name = '', $className = '')

&lt; function &amp;addFormat($properties = array())
&gt; function &amp;addFormat($properties = array(), $className = '')

...

And then reimplement thouse methods to support different classes:

&lt; $worksheet = new Spreadsheet_Excel_Writer_Worksheet(...

&gt; if (! class_exists($className)) {
&gt;     $className = 'Spreadsheet_Excel_Writer_Worksheet';
&gt; }
&gt; $worksheet = new $className(...
&gt; if (! is_a($worksheet, 'Spreadsheet_Excel_Writer_Worksheet')) {
&gt;     $this-&gt;raiseError('Custom class do not extends Spreadsheet_Excel_Writer_Worksheet', 0, PEAR_ERROR_DIE);
&gt; }

...and the same for all other classes.</pre>]]></description>
      <dc:date>2009-08-11T22:45:43+00:00</dc:date>
      <dc:creator>dan &amp;#x61;&amp;#116; yes &amp;#x64;&amp;#111;&amp;#x74; lt</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Feature/Change Request</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/3203">
      <title>Spreadsheet_Excel_Writer: Bug 3203 [Verified] Formulas not opening properly in Excel</title>
      <link>http://pear.php.net/bugs/3203</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by dbadekas@...
2005-01-14T12:09:03+00:00
PHP: 4.3.1 OS: irrelevant Package Version: 0.9.2

Description:
------------
The formulas produced by Spreadsheet_Excel_Writer are not produced when opened with Excel(2000). OpenOffice(1.1/1.0) has no problem and displays the formula values as expected.

Excel opens by displayin the #VALUE in place of the formulas.
The formulas are correct, because: 
1) OOffice and Gnumeric open correctly
2) In Excel, when you click on the formlula in the edit field and hit return, then the formula pops a value ( which is correct)
3) Improting the file to OOffice and re-exporting to excel corrects this problem.

I will include a sample file later</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by dbadekas@...
2005-01-14T12:09:03+00:00
PHP: 4.3.1 OS: irrelevant Package Version: 0.9.2

Description:
------------
The formulas produced by Spreadsheet_Excel_Writer are not produced when opened with Excel(2000). OpenOffice(1.1/1.0) has no problem and displays the formula values as expected.

Excel opens by displayin the #VALUE in place of the formulas.
The formulas are correct, because: 
1) OOffice and Gnumeric open correctly
2) In Excel, when you click on the formlula in the edit field and hit return, then the formula pops a value ( which is correct)
3) Improting the file to OOffice and re-exporting to excel corrects this problem.

I will include a sample file later</pre>]]></description>
      <dc:date>2009-11-29T02:34:06+00:00</dc:date>
      <dc:creator>dbadekas &amp;#x61;&amp;#116; aia &amp;#x64;&amp;#111;&amp;#x74; gr</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/3148">
      <title>Spreadsheet_Excel_Writer: Bug 3148 [Verified] write() works incorrectly for some locales</title>
      <link>http://pear.php.net/bugs/3148</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by bugs.php.net@...
2005-01-10T06:48:29+00:00
PHP: 5.0.3 OS: Linux Package Version: 

Description:
------------
Calling $worksheet-&gt;write($row, $col, 1.2) will write &quot;1,2&quot; as a string instead of a number when the locale for LC_NUMERIC has been set to a locale that uses &quot;,&quot; as a decimal seperator instead of &quot;.&quot; (e.g. da_DK).

The method Spreadsheet_Excel_Writer_Worksheet::write() tries to determine whether the argument is a number by using preg_match(). However, preg_match() takes a string argument, so the float value is converted to a string. The string uses the decimal seperator specified by the current locale. If this is &quot;,&quot;, the string does not match the regular expression used to determine whether the argument is a number.

Why not just use is_numeric() instead of preg_match()?</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by bugs.php.net@...
2005-01-10T06:48:29+00:00
PHP: 5.0.3 OS: Linux Package Version: 

Description:
------------
Calling $worksheet-&gt;write($row, $col, 1.2) will write &quot;1,2&quot; as a string instead of a number when the locale for LC_NUMERIC has been set to a locale that uses &quot;,&quot; as a decimal seperator instead of &quot;.&quot; (e.g. da_DK).

The method Spreadsheet_Excel_Writer_Worksheet::write() tries to determine whether the argument is a number by using preg_match(). However, preg_match() takes a string argument, so the float value is converted to a string. The string uses the decimal seperator specified by the current locale. If this is &quot;,&quot;, the string does not match the regular expression used to determine whether the argument is a number.

Why not just use is_numeric() instead of preg_match()?</pre>]]></description>
      <dc:date>2009-08-11T22:36:35+00:00</dc:date>
      <dc:creator>bugs &amp;#x64;&amp;#111;&amp;#x74; php &amp;#x64;&amp;#111;&amp;#x74; net &amp;#x61;&amp;#116; chsc &amp;#x64;&amp;#111;&amp;#x74; dk</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/2862">
      <title>Spreadsheet_Excel_Writer: Bug 2862 [Verified] insertBitmap scales image incorrect in Excel 2000</title>
      <link>http://pear.php.net/bugs/2862</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by thomas.keller@...
2004-12-01T04:41:15+00:00
PHP: 4.3.4 OS: RH9 Package Version: 

Description:
------------
In Excel 2000 a bitmap is always scaled incorrectly if
it is inserted via insertBitmap (and no scale/ position
attributes), regardless where I put the image.

The author of _positionImage in Worksheet.php notes that

&quot;the SDK incorrectly states that the height should be 
expressed as a percentage of 1024.&quot;

thus uses for the height a value of only 256.
I changed these values to 1024 which made the insert
work correctly for me.


Reproduce code:
---------------
 $file = &quot;/path/to/file/bitmap.bmp&quot;;
 $worksheet-&gt;insertBitmap(0, 0, $file);</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by thomas.keller@...
2004-12-01T04:41:15+00:00
PHP: 4.3.4 OS: RH9 Package Version: 

Description:
------------
In Excel 2000 a bitmap is always scaled incorrectly if
it is inserted via insertBitmap (and no scale/ position
attributes), regardless where I put the image.

The author of _positionImage in Worksheet.php notes that

&quot;the SDK incorrectly states that the height should be 
expressed as a percentage of 1024.&quot;

thus uses for the height a value of only 256.
I changed these values to 1024 which made the insert
work correctly for me.


Reproduce code:
---------------
 $file = &quot;/path/to/file/bitmap.bmp&quot;;
 $worksheet-&gt;insertBitmap(0, 0, $file);</pre>]]></description>
      <dc:date>2009-11-29T02:06:57+00:00</dc:date>
      <dc:creator>thomas &amp;#x64;&amp;#111;&amp;#x74; keller &amp;#x61;&amp;#116; inatec &amp;#x64;&amp;#111;&amp;#x74; com</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
    <item rdf:about="http://pear.php.net/bug/2146">
      <title>Spreadsheet_Excel_Writer: Bug 2146 [Verified] setversion(8) used with printArea crashes Excel</title>
      <link>http://pear.php.net/bugs/2146</link>
      <content:encoded><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by pwa.net@...
2004-08-17T07:32:32+00:00
PHP: 4.3.1 OS: unix Package Version: 

Description:
------------
setversion(8) used with printArea crashes Excel
Use excel spreadsheet 0.8,
OLE 5.0

Reproduce code:
---------------
require_once 'Spreadsheet/Excel/Writer.php';
// Creating a workbook
$workbook = new Spreadsheet_Excel_Writer();
$workbook-&gt;SetVersion(8);

// sending HTTP headers
$workbook-&gt;send('test.xls');

// Creating a worksheet
$worksheet1 =&amp; $workbook-&gt;addWorksheet('Premier feuillet');

// The actual data
$worksheet1-&gt;write(3, 2, 'Ce fichier Ã  Ã©tÃ© entiÃ¨rement gÃ©nÃ©rÃ© avec PHP');

// BUG WITH THIS LINE
$worksheet1-&gt;printArea(1,1,5,5);

// Let's send the file
$workbook-&gt;close();

Actual result:
--------------
Excel crashes</pre>]]></content:encoded>
      <description><![CDATA[<pre>Spreadsheet_Excel_Writer Bug
Reported by pwa.net@...
2004-08-17T07:32:32+00:00
PHP: 4.3.1 OS: unix Package Version: 

Description:
------------
setversion(8) used with printArea crashes Excel
Use excel spreadsheet 0.8,
OLE 5.0

Reproduce code:
---------------
require_once 'Spreadsheet/Excel/Writer.php';
// Creating a workbook
$workbook = new Spreadsheet_Excel_Writer();
$workbook-&gt;SetVersion(8);

// sending HTTP headers
$workbook-&gt;send('test.xls');

// Creating a worksheet
$worksheet1 =&amp; $workbook-&gt;addWorksheet('Premier feuillet');

// The actual data
$worksheet1-&gt;write(3, 2, 'Ce fichier Ã  Ã©tÃ© entiÃ¨rement gÃ©nÃ©rÃ© avec PHP');

// BUG WITH THIS LINE
$worksheet1-&gt;printArea(1,1,5,5);

// Let's send the file
$workbook-&gt;close();

Actual result:
--------------
Excel crashes</pre>]]></description>
      <dc:date>2009-11-29T02:43:07+00:00</dc:date>
      <dc:creator>pwa &amp;#x64;&amp;#111;&amp;#x74; net &amp;#x61;&amp;#116; free &amp;#x64;&amp;#111;&amp;#x74; fr</dc:creator>
      <dc:subject>Spreadsheet_Excel_Writer Bug</dc:subject>
    </item>
</rdf:RDF>
