You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm trying to set a widescreen, 13.333" x 7.5" size for my PowerPoint document.
fFom the samples (and what I can understand from the source) this should work
$objPHPPowerPoint = new PhpPresentation();
$objPHPPowerPoint->getLayout()->setDocumentLayout(DocumentLayout::LAYOUT_CUSTOM)
->setCX(13.333,DocumentLayout::UNIT_INCH)
->setCY(7.5,DocumentLayout::UNIT_INCH);
but I get the following error
Fatal error: Uncaught TypeError: Cannot access offset of type string on string in
C:\...d\vendor\phpoffice\phppresentation\src\PhpPresentation\DocumentLayout.php:138
Stack trace:
#0 C:\...\pptx.php(30): PhpOffice\PhpPresentation\DocumentLayout->setDocumentLayout('custom')
#1 {main}
thrown in C:\...d\vendor\phpoffice\phppresentation\src\PhpPresentation\DocumentLayout.php on line 138
Using LAYOUT_SCREEN_16X9 and LAYOUT_OVERHEAD don't throw an error in generation, but PowerPoint repairs the file on opening
The text was updated successfully, but these errors were encountered:
I'm trying to set a widescreen, 13.333" x 7.5" size for my PowerPoint document.
fFom the samples (and what I can understand from the source) this should work
but I get the following error
Using
LAYOUT_SCREEN_16X9
andLAYOUT_OVERHEAD
don't throw an error in generation, but PowerPoint repairs the file on openingThe text was updated successfully, but these errors were encountered: