I've been trying to copy a graph that is in an Excel template. With the aim of updating the graph by using PHPExcel to modify the associated data.
I've used the 30template.php example to achieve a lot of this, though it is missing the title, labels and doesn't keep the colours that I set.
The relevant snippets are:
$inputFileType = 'Excel2007';
$inputFileName = '/var/www/ReportTemplates/ExcelReportTemplate.xlsx';
$objReader = PHPExcel_IOFactory::createReader($inputFileType);
$objPHPExcel = $objReader->load($inputFileName);
$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');
I can see how these components are set when creating a new graph, though not when using a template. I've hunted around for quite a while though no luck.
Am I missing something?