Inserting Images Error

Topics: Developer Forum
Jul 1, 2011 at 6:19 PM

Hi everybody, i'm a novice in PHPExcel, i dont can insert a image in my worksheet, my code:

$objWorksheet = $objPHPexcel->setActiveSheetIndex(1);
$objDrawing = new PHPExcel_Worksheet_Drawing();
$objDrawing->setName('Logo');
$objDrawing->setDescription('Logo');
$objDrawing->setPath('./imagens/relatorios/example1.jpg');
$objDrawing->setHeight(36);
$objDrawing->setCoordinates('B15');
$objDrawing->setOffsetX(110);
$objDrawing->setRotation(25);
$objDrawing->getShadow()->setVisible(true);
$objDrawing->getShadow()->setDirection(45);
$objDrawing->setWorksheet($objPHPExcel->getActiveSheet());

When a comment the last line the script pass but no image in document. Where is the error? Help me.

I'm sorry for my bad english.