Hi, I'm trying to create a PDF Document from a JSP, I have this code to do
it.

****** freniltest.jsp ***** 
<%@ page import="com.lowagie.text.*" %><%@ page import="java.io.*" %><%@
page import="com.lowagie.text.pdf.PdfWriter"%><%@ page impo
rt="com.lowagie.text.pdf.ColumnText"%><%@ page
import="com.lowagie.text.pdf.PdfContentByte"%><%@ page
import="com.lowagie.text.pdf.BaseFont"%><% 

java.awt.Color border = new java.awt.Color(0xED, 0x1C, 0x24); 
Font font1 = new Font(Font.HELVETICA, 14, Font.NORMAL, border); 
Font font2 = new Font(Font.HELVETICA, 24, Font.BOLD, border); 
Font font3 = new Font(Font.HELVETICA, 12, Font.NORMAL, border); 
Document document = new Document(PageSize.A4, 30, 30, 80, 50); 
document.addSubject("Test"); 
java.io.ByteArrayOutputStream baos = new java.io.ByteArrayOutputStream(); 
PdfWriter writer = PdfWriter.getInstance(document, baos); 
document.open(); 
Paragraph p = new Paragraph("Hello world",font1); 
document.add(p); 
document.newPage(); 
document.close(); 
response.setContentType("application/pdf"); 
response.setContentLength(baos.size()); 
ServletOutputStream myOut = response.getOutputStream(); 
baos.writeTo(myOut); 
myOut.flush(); 
%> 
******SNIPP!***** 
******** SNIPP! index.jsp **** 
<html> 
<head> 
<script> 
function showPrintFrenilTest() 
{ 
window.open("freniltest.jsp","myWin"); 
} 
</script> 
</head> 
<body> 
<br> 
<a href="">Freniltest</a> 
<br>
</body> 
</html> 


and I'm developing in JDeveloper 3.2.3 but when i runing de JSP, show me
some error like this ones:

C:\Program Files\Oracle\JDeveloper 3.2.3\myhtml\PDF_html\prueba1.jsp
Warning: (0) ISO-8859-1 character set may not match project compiler
setting.
Error: (0) identifier com.lowagie.text.pdf.PdfWriter not found.
Error: (0) identifier com.lowagie.text.pdf.ColumnText not found.
Error: (0) identifier com.lowagie.text.pdf.PdfContentByte not found.
Error: (0) identifier com.lowagie.text.pdf.BaseFont not found.
Error: (11) class Font not found in class pdf_html.prueba1.
Error: (11) class Font not found in class pdf_html.prueba1.
Error: (11) variable Font not found in class pdf_html.prueba1.
Error: (11) variable Font not found in class pdf_html.prueba1.
Error: (12) class Font not found in class pdf_html.prueba1.
Error: (12) class Font not found in class pdf_html.prueba1.
Error: (12) variable Font not found in class pdf_html.prueba1.
Error: (12) variable Font not found in class pdf_html.prueba1.
Error: (13) class Font not found in class pdf_html.prueba1.
Error: (13) class Font not found in class pdf_html.prueba1.
Error: (13) variable Font not found in class pdf_html.prueba1.
Error: (13) variable Font not found in class pdf_html.prueba1.
Error: (14) class Document not found in class pdf_html.prueba1.
Error: (14) class Document not found in class pdf_html.prueba1.
Error: (14) variable PageSize not found in class pdf_html.prueba1.
Error: (17) class PdfWriter not found in class pdf_html.prueba1.
Error: (17) variable PdfWriter not found in class pdf_html.prueba1.
Error: (19) class Paragraph not found in class pdf_html.prueba1.
Error: (19) class Paragraph not found in class pdf_html.prueba1.
C:\Program Files\Oracle\JDeveloper 3.2.3\myhtml\PDF_html\prueba.jsp
Error: (0) error reading directory: C:\Ejecutables\itext-0.99.jar: bad zip
file.


so i want to know where can i download de Api that have this libraries,
because i think that is the problem, i do not have this library or API,
i hope that you can help me!!!

Thank you.



-------------------------------------------------------
This SF.net email is sponsored by:  Etnus, makers of TotalView, The best
thread debugger on the planet. Designed with thread debugging features
you've never dreamed of, try TotalView 6 free at www.etnus.com.
_______________________________________________
iText-questions mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/itext-questions

Reply via email to