jsp - converting into html form to pdf -
i making student admission form student name,mobile,phone number, father name etc etc. have 2 tables of 10 rows , 6 columns details entered in new student shown in proper form in next page (example- design html page how original form looks like). want save pdf.
i applied code shows error.
code
string s=""; try{ string ref=request.getheader("referer"); url url = new url(ref); bufferedreader reader = new bufferedreader(new inputstreamreader(url.openstream())); string line; while ((line = reader.readline()) != null){ s=s+line; } document doc=new document(pagesize.a5.rotate()); file f=new file("c:\\users\\diljeet\\desktop\\data111.pdf"); pdfwriter.getinstance(doc, new fileoutputstream("c:\\users\\diljeet\\desktop\\data111.pdf")); doc.open(); htmlworker htmlworker = new htmlworker(doc); htmlworker.parse(new stringreader(s)); doc.close(); reader.close(); }catch(exception e){ system.out.println(e); }
error
java.io.ioexception: server returned http response code: 500 url: http://localhost:8084/finalproject/fillfeedbackformaction.jsp
Comments
Post a Comment