multitool wrote:
> I'm trying to do a simple task of scaling down a PDF. I found two samples on
> the Internet that demonstrate exactly what I want, but when I try to compile
> the code I get an error. It says it can't find the symbol for the
> addTemplate method, but the method call looks correct to me according to the
> API documentation. What am I doing wrong? This is the code and the error:

It's a very subtle error. Look at what I added to your code.

> cb.addTemplate( page, 0.1f, 0.0f, 0.0f, 0.1f, 0.0f, 0.0f );

> javac.exe -classpath iText-5.0.1.jar TestProg.java
> TestProg.java:14: cannot find symbol
> symbol  : method
> addTemplate(com.itextpdf.text.pdf.PdfImportedPage,double,double,double,double,double,double)
> location: class com.itextpdf.text.pdf.PdfContentByte
>                 cb.addTemplate( page, 0.1, 0.0, 0.0, 0.1, 0.0, 0.0 );

iText expects floats not doubles ;-)
-- 
This answer is provided by 1T3XT BVBA
http://www.1t3xt.com/ - http://www.1t3xt.info

------------------------------------------------------------------------------
SOLARIS 10 is the OS for Data Centers - provides features such as DTrace,
Predictive Self Healing and Award Winning ZFS. Get Solaris 10 NOW
http://p.sf.net/sfu/solaris-dev2dev
_______________________________________________
iText-questions mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/itext-questions

Buy the iText book: http://www.1t3xt.com/docs/book.php
Check the site with examples before you ask questions: 
http://www.1t3xt.info/examples/
You can also search the keywords list: http://1t3xt.info/tutorials/keywords/

Reply via email to