Thanks!
I tried exporting multiple images, with different row/col position and it 
exports them fine.
 
But I tried to fit the image to single column and row - i.e. resize row and 
column to fit the image, but somehow the row does not resize.
Also, the image stretches as much as I increase the column width.
I have used the following code:
        sheet.setColumnWidth((short)2, (short)7500);
        sheet.setDefaultRowHeight((short) 3000);
 
Also, if I need to fit the image to just 1 column and 1row and not span 
multiple cols/rows, how should the following API be used:
anchor = new HSSFClientAnchor(0,0,0,255,(short)2,2,(short)4,7);
I am quite confused on the x/y coordinates.
Any help on its usage would be appreciated.
 
Thanks,
Prachi

________________________________

From: Nick Burch [mailto:[EMAIL PROTECTED]
Sent: Mon 15/10/2007 11:19
To: POI Users List
Subject: RE: Export an image as PNG to a particular cell in Excel using POI.



On Fri, 12 Oct 2007, [EMAIL PROTECTED] wrote:
> Yes, the positioning can be achieved, but then as the documentation
> says, that any existing image would be erased with the new image.

I didn't write the code so I can't be sure, but I have a feeling that the
warning relates to images already in the file when you start, not ones you
add in. So, you ought to be fine to open the file up, and add several
images to it before closing.

Nick

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to