Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

How to add different images to different sheets in excel using POI..?  RSS feed

 
santhosh.R gowda
Ranch Hand
Posts: 296
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Dear all

I have a reqiurement where in i want to add different images to different sheets of a excel using POI . as of now the image is getting overwritten . so can you please let me know how the requirement can be achieved.
 
manoj r patil
Ranch Hand
Posts: 182
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You can check the example OfficeDrawing.java which demonstrates adding images on different sheets. If you will download the source code, all the examples are included there.

Basically you will have to get handle of different sheets and set the anchor using HSSFClientAnchor and then add the images.
 
Consider Paul's rocket mass heater.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!