views:

226

answers:

1

in vb.net is it possible to get the coordinates of an image like if i do a

document.add (jpeg_image)
x_coordinate = jpeg_image.xcoordinate???????
+1  A: 

If you're trying to get this info while you are building the PDF document:

The x-coordinate of the left edge of your image will depend on how the image was added to the PDF document. If you use an absolute position to add it, you'll have your x-coordinate. If you just add it, without absolute position, or any other modifiers, the x-coordinate will be equal to whatever the left margin is, since that is the default. If you've specified that the image should be centered or left-justified, then you'll need your image width and your margins to figure the location of the left edge of the image.

If you're trying to get this info from an already-created and saved PDF file:

Jay is right, there is no method in iTextSharp to do this.

Stewbob