Skip to content

ChangeSheet not doing anything for XLSX #60

@osuwariboy

Description

@osuwariboy

Hey there,

  When you open an XLSX file and call ChangeSheet as your first operation, ChangeSheet will not change the sheet. This is because of the following condition in the rewind method:

if ($this -> Index > 0 || !($this -> Worksheet instanceof XMLReader))

This is because, if you haven't done anything,

$this->Index is 0 and $this->Worksheet is indeed an instance of XMLReader since the first sheet was loaded. So to fix this, either unset $this->Worksheet or set $this->Index to 1 in the ChangeSheet method, this way, rewind will successfully load the correct worksheet when it's called.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions