0

i have seen countless of posts about how to insert pictures or images into word documents using Apache POI. There is a major problem to this: I can not say, where exactly to put them. Of course you can put them into a certain segment using the alignment option, but this seems to me a little bit lack luster. What i would like to have is something along the lines of

insert(xcoord, ycoord, width, length, pictureName);

but i have not seen this being done anywhere. Is there already an elegant approach of how to implement this?

Because another issue with this is the following: Yeah, of course i could take the Microsoft XML code and parse this xml with the wanted data, but that is kind of a pain in the arse and not efficient at all. So yeah, that's that.

Greetings, newbie

newbie
  • 117
  • 12
  • Try this answer - http://stackoverflow.com/a/29922512/4720017 – LittlePanda May 08 '15 at 09:48
  • Correct me if i am wrong, but just by looking at the code i can tell: there is no option to modify the location of the image. Or am i missing something? – newbie May 08 '15 at 09:51
  • 1
    This sounds more like a rant than a question. As such it is not on-topic. Please edit it to present your specific programming problem without the noise. – RealSkeptic May 08 '15 at 09:53
  • Just to make sure there is no cofusion: I want to create highly structured word files, where i insert graphic and stylistic elements( textboxes, formatted text, images etc.) to certain locations, that need not be moved **after** insertion. – newbie May 08 '15 at 09:54
  • I am not aware on how to set the location. That code can set the size and then you can try setting the indentation to get close to your expected output. – LittlePanda May 08 '15 at 09:55
  • @RealSkeptic leave out the last paragraph and you get the programming problem. – newbie May 08 '15 at 09:55

0 Answers0