Free Support Forum - aspose.com

Image + Data to PDF

I need to produce a packing slip. Two pieces of information need to be merged together in one PDF and specific placement within the PDF is important. First piece of information is a a fedex label as a PNG or a filestream. The second piece of information is data I'll be pulling from a sql database. Is it possible to use Aspose.PDF to combine these pieces of information in one PDF? The fedex image needs to be sized as a 4x6. I'm comfortable with creating sections and adding objects to the sections but I can't figure out how to size my image or position my information.

Any help would be appreciated.

Hello Tina,

Thanks for considering Aspose.

I'm pleased to inform you that, both of your requirements i.e. placing an image along with setting its size and addition of contents at specific location within the document is possible. In order to set the size of image you can use ImageInfo.FixHeight or ImageInfo.FixWidth properties. You may also use the Image.ImageScale property to specify the scale rate of the image.

In order to properly specify/place the contents within the document, I would recommend you to use tables and place the contents inside table cells. For details on how to fetch information from database and display within a table of PDF document, please visit Integrate Table with Database

I would also suggest you to visit the following links, and I believe they would be helpful to you.

In case it does not satisfy your requirement or you've any further query, please feel free to contact.