Crashes?  I assume that's another way of saying "it throws an exception"?

What exception is thrown?  That's a remarkably useful piece of information.

--Mark Storer
  Senior Software Engineer
  Cardiff Software

#include <disclaimer>
typedef std::Disclaimer<Cardiff> DisCard;



> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] Behalf Of
> Sierra Bravo
> Sent: Saturday, September 09, 2006 2:11 AM
> To: [email protected]
> Subject: [iText-questions] Adding destination with PDFContentByte
> 
> 
> 
> What am I doing wrong here? The programme crashes after 
> processing the first
> page where there is a destination.
> 
> //A reader has been opened
> int n = reader.getNumberOfPages();
> Document document = new Document();
> PdfCopy writer = new PdfCopy(document, new
> FileOutputStream(outputFileName));
> document.open();
> for(int i=1; i<=n; i++) {
>     writer.addPage(writer.getImportedPage(reader, i));
> 
>    // Dest is a hashmap of type Map<Integer, 
> java.util.List<Destination>> 
>    // where Destination is a convenience class
>     if (dest.containsKey(i)) { 
>         java.util.List<Destination> thispage;
>         PdfContentByte cb = writer.getDirectContent();
>         thispage=dest.get(i);
>         for (Destination d : thispage) 
>            // d.getName looks like "Para 150"  and 
> d.getPdfDestination 
>            // is of type PdfDestination, and looks like 
> [/XYZ,0,782,1.25]
>             
> cb.localDestination(d.getName(),d.getPdfDestination());       
>                           
>         }
> 
> TIA
> 
> s.b.
> 
> -- 
> View this message in context: 
> http://www.nabble.com/Adding-destination-with-PDFContentByte-t
f2243210.html#a6221907
Sent from the iText - General forum at Nabble.com.


-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
iText-questions mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/itext-questions

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
iText-questions mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/itext-questions

Reply via email to