If INTERN is not /INTERN then it's not a pdf object. I'm curious about what
Oc� exactly says in the documentation and what they expect the generator of
this append block to be, certainly not Acrobat..
iText could generate this append block with some custom code, probably an
extension to PdfWriter.

Best Regards,
Paulo Soares


> -----Original Message-----
> From: Carsten Hammer [SMTP:[EMAIL PROTECTED]
> Sent: Monday, September 22, 2003 14:15
> To:   [EMAIL PROTECTED]
> Subject:      [iText-questions] Re: Re: appending a pdf document update
> block
> 
> Hi Paulo,
> great, that nearly works (changed the second PdfName() to PdfLiteral()).
> The
> only thing that still seems to be problematic is that this is not a pdf
> update block but part of a single catalog. Do you think any low level
> functions of itext could be reused to implement something to generate
> document update blocks?
> Thank you very much,
> Best regards,
> Carsten
> 
> 
> 
> "Paulo Soares" <[EMAIL PROTECTED]> schrieb im Newsbeitrag
> news:[EMAIL PROTECTED]
> Here's some code to add an hanging stream:
> 
> import java.io.*;
> import com.lowagie.text.*;
> import com.lowagie.text.pdf.*;
> 
> public class oce_block {
>     public static void main(String args[]) {
>         try {
>             PdfReader originalPDF = new PdfReader( "c:\\file.pdf" );
>             FileOutputStream os = new FileOutputStream(
> "c:\\oce_block.pdf"
> );
>             PdfStamper stamper = new PdfStamper(originalPDF, os);
>             PdfWriter writer = stamper.getWriter();
>             byte b[] = "Something to put inside the stream.".getBytes();
>             PdfStream stream = new PdfStream(b);
>             stream.put(new PdfName("INFOBLOCK"), new PdfName("INTERN"));
>             stream.flateCompress();
>             writer.addToBody(stream);
>             stamper.close();
>         }
>         catch ( Exception e ) {
>             e.printStackTrace();
>         }
>     }
> }
> 
> 
> 
> 
> 
> 
> -------------------------------------------------------
> This sf.net email is sponsored by:ThinkGeek
> Welcome to geek heaven.
> http://thinkgeek.com/sf
> _______________________________________________
> iText-questions mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/itext-questions


-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
iText-questions mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/itext-questions

Reply via email to