GithubHelp home page GithubHelp logo

Comments (4)

arnaudelub avatar arnaudelub commented on August 17, 2024 2

Hi there, thanks for your answer, i'm using this code for hundreds of xls / xlsx / csv files and it works well except for some of them:

$reader = \PhpOffice\PhpSpreadsheet\IOFactory::createReaderForFile($file);
$reader->setReadDataOnly(true);
$objReader=$reader->load($file);
$writer = \PhpOffice\PhpSpreadsheet\IOFactory::createWriter($objReader, "CSV");
$writer->save("test.csv");

The XMLThemeName object appears to be empty, so there is no $xmlTheme->themeElements->clrScheme->attributes();

I can't give you the xlsx file here but here is the theme.xml
phpSpreadsheet_error_theme.txt

Thanks for your help!

from phpspreadsheet.

PowerKiKi avatar PowerKiKi commented on August 17, 2024

The description seems to lack important information to do anything about it. Closing for now, but feel free to add a fully reproducible example of code that reproduce the issue and reopen it.

from phpspreadsheet.

Quix0r avatar Quix0r commented on August 17, 2024

@BadTasTe- are you sure, you use a CSV file with this? Because The failing class in Xlsx which hints that your file is maybe an XLSX (new M$ Office format) or your code is something nasty.

Please provide a code as @PowerKiKi asked for.

from phpspreadsheet.

 avatar commented on August 17, 2024

I am facing the same issue with couple of xlsx file. Unfortunately, we are not at the liberty to share the files to be able to reproduce in-house for you.

Fatal error: Uncaught Error: Call to a member function attributes() on null in C:\Apache24\htdocs\vendor\vendor\phpoffice\phpspreadsheet\src\PhpSpreadsheet\Reader\Xlsx.php:1723

from phpspreadsheet.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.