LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

PDF Creation: Inserting a jpg Image

Hi All,

 

This is a Cross Post to from Adobe Forums as they do not allow attatching files...  However if anyone can help here it would be appreciated.  I am creating this PDF from LabVIEW but hit a stumbling block.


Hello All,

First Post In the Adobe Forums so please excuse if this is in the wrong forum.

I am trying to create a PDF file from scratch by going through the PDF Specification. I have had Success with tables shapes and text however I cannot seem to get an Image embedded correctly. I was hoping someone may be able to take a look of the formatting of my PDF and see wht is going wrong. Any other general tips as to the structure would also be welcome. The PDF file isnt to large and the picture I am trying to embedd is 32x32 px jpg with 8 Bits per Component. My Current Method is to open the jpg File as a Binary File and insert the whole Byte stream between the "stream" and "endstream" tags.

 

Thanks
Craig

 

 

 

LabVIEW 2012
Download All
0 Kudos
Message 1 of 6
(3,457 Views)

I have now resolved this issue.  I was writing the PDF as a text file and had the auto replace EOL characters enabled which was messing up the JPG stream.

 

Thanks

Craig

LabVIEW 2012
Message 2 of 6
(3,390 Views)

Hello Craig,

 

   I am first time trying to create PDF and not aware about anything.

   My PDF creation requirement is, it contains text, tables and logos.

   Can you please provide me guidance to proceed on creation of PDF?

 

    FYI... I am searching for help and found that your comment on Adobe coding web page that you have able to create the text, tables and images in PDF creation.

 

Thanx and Regards,

Tau

0 Kudos
Message 3 of 6
(3,305 Views)

Hello Tau,

 

I have indeed managed to cretae PDF files from pure LabVIEW without the use of any third party Libraries.  It is pretty tough going though and if you have no need to write this yourself (i.e no 3rd party toolsets allowed by your company) then I would suggest using one of the available libraries found on the NI tools site.

 

If you really want to create them from scratch then I found the following resources helpfull.

https://blog.idrsolutions.com/2013/01/understanding-the-pdf-file-format-overview/

http://itextpdf.com/Products/itext-rups

And of course the PDF file format specification.

http://www.adobe.com/devnet/pdf/pdf_reference_archive.html

 

If I could I would of shared my code by now.  Tree controls are a big help if you are familiar with them.

Thanks

Craig

 

 

LabVIEW 2012
0 Kudos
Message 4 of 6
(3,119 Views)

Hello craigc


This same issue I am facing while making pdf from scratch and writing as a string. Can you please help me to resolve this, or tell me how you resolved it.

0 Kudos
Message 5 of 6
(112 Views)

@AmberPrakash wrote:

Hello craigc


This same issue I am facing while making pdf from scratch and writing as a string. Can you please help me to resolve this, or tell me how you resolved it.


This is an 8 year old discussion and since you don't really tell us what you are doing or what errors you get, we cannot help.

0 Kudos
Message 6 of 6
(95 Views)