For the complete documentation index, see llms.txt. This page is also available as Markdown.

Check worksheet exists

Function Prototype

existSheet(string $sheetName): bool

Example

$config = ['path' => './tests'];

$fileObject = new \Vtiful\Kernel\Excel($config);

$fileObject->fileName('tutorial.xlsx')
    // add a worksheet named twoSheet
    ->addSheet('twoSheet');

var_dump($fileObject->existSheet('twoSheet'));
var_dump($fileObject->existSheet('notFoundSheet'));

Example output

bool(true)
bool(false)

Last updated