|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #50908 Office 2007 error
Submitted: 2010-02-02 11:51 UTC Modified: 2020-02-09 04:22 UTC
From: niragorri at hotmail dot com Assigned: cmb (profile)
Status: No Feedback Package: COM related
PHP Version: 5.3SVN-2010-02-02 (SVN) OS: Windows 7
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Bug Type:
From: niragorri at hotmail dot com
New email:
PHP Version: OS:


 [2010-02-02 11:51 UTC] niragorri at hotmail dot com
There is an error when using Office 2007 to access an excel sheet when your under Windows XP using the php COM class. But you can still access it. However, if you're using Windows 7 with any version of office you can't use the COM class to access the excel file. The same script that worked for me under XP was useless in 7.

Reproduce code:
$excel = new COM ("Excel.sheet");
			$excel->Application->DisplayAlerts = false;
			$abrir = $excel->application->Workbooks->Open($hojita);
			$excel->Application->Visible = 1;
			//se abre la hoja1 donde se encuentran los datos del proyecto y se llama a la funcion llenarformato
			$hoja = $abrir->Worksheets("Hoja1");
			while (utf8_encode ($hoja->Cells(1, $contcol))!= ""){
			while (utf8_encode ($hoja->Cells($contfil, 1))!= ""){

Expected result:
I expected it to access an excel document and report the number of columns and rows of a specific sheet. In most Windows 7 systems


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2020-01-27 13:31 UTC]
-Status: Open +Status: Feedback -Assigned To: +Assigned To: cmb
 [2020-01-27 13:31 UTC]
The script (with necessary modifications) works for me on Windows
10 Version 1909 with PHP 7.3.14.  Do you still experience issues?
If so, please provide the error message(s) reported by PHP.
 [2020-02-09 04:22 UTC] php-bugs at lists dot php dot net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Re-Opened". Thank you.
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Mon Jul 22 09:01:28 2024 UTC