poi-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Heck Markus <Markus.H...@mgi.de>
Subject Adding an image to Excel
Date Thu, 12 Jan 2006 15:45:27 GMT
Hello,

currently, I'm able to add an image to Excel using following approach:

      HSSFWorkbook workBook3 = new HSSFWorkbook( byteArrayInput );      
      HSSFPatriarch patriarch = workBook3.getSheetAt( 0
).createDrawingPatriarch();
      HSSFClientAnchor anchor = new HSSFClientAnchor( 0, 0, 0, 0, (short)2,
18, (short)bildEndeX, bildEndeY);
      anchor.setAnchorType( 3 );
      patriarch.createPicture( anchor, workBook3.addPicture( byteImage,
HSSFWorkbook.PICTURE_TYPE_JPEG ) );

But by using this approach the images look distorted. Is there any
possibility to add an image
to excel without using cell boundaries (like it is possible in Excel
itself)?
Thanks in advance!

Markus

---------------------------------------------------------------------
To unsubscribe, e-mail: poi-user-unsubscribe@jakarta.apache.org
Mailing List:     http://jakarta.apache.org/site/mail2.html#poi
The Apache Jakarta Poi Project:  http://jakarta.apache.org/poi/


Mime
View raw message