[iText-questions] Table of Contents

2004-03-10 Thread Dunstall, Christopher



I know it's possible to do page numbers, but 
I was wondering if it were possible to produce a table of contents (like word 
does).
The primary use for my implementation of the pdf is to be printed out, 
and the client would like a table contents...
 
Is this possible?
 
~~
Chris 
Dunstall
Analyst 
Programmer
 
Admin 
Computing
Bathurst 
Campus

Charles Sturt 
University
 
E-Mail:  
[EMAIL PROTECTED]
Phone:   +61 2 63384818
Fax: +61 2 63384181
Mobile:  
+61 0438 324 180
~~
 
<>

[iText-questions] HTML tags covered by the Parser...

2004-03-04 Thread Dunstall, Christopher



Hi all (this is mainly aimed at Bruno, but 
anyone else who knows can answer)
 
Finally got this thing going, only to find 
it doesn't cover the tags I need it to cover...
 
Basic formatting is obviously covered, but 
the following HTML tags aren't coming through in the parser...
 


 
Should they be coming through or are they 
not covered?
 
Here is a block of HTML that I am trying to 
parse...
 
This is a large block of text that 
I can write in this text field because I have to write a large block of text so 
that I can fill in the space of where something with a large block of text might 
be.  This large block of text is to represent the Enrolment 
Pattern.More indented 
Text.Not indented 
text
 
Hope someone can help.
 
Background info...
 
Just for those are interested, I modified 
the code to turn on the option to toggle opening and closing the pdf document, 
as I am writing to it from a database with has some html and some not html 
elements (ie the first part of the pdf is straight text, a bit in the middle 
will be html and the last bit would be straight text again).
 
So the above html is wrapped 
with:
 
String newHtml = 
"";newHtml += "";newHtml += "";
html goes here
newHtml += 
"";
 
and then parse it.
 
 
 
 
~~
Chris 
Dunstall
Analyst 
Programmer
 
Admin 
Computing
Bathurst 
Campus

Charles Sturt 
University
 
E-Mail:  
[EMAIL PROTECTED]
Phone:   +61 2 63384818
Fax: +61 2 63384181
Mobile:  
+61 0438 324 180
~~
 
<>

RE: FW: [iText-questions] HTML to PDF Question...

2004-01-13 Thread Dunstall, Christopher
Hi, thanks for the help, I've modified the HTML and made a note of the
fragment problem.

However, I've double checked the classpath and the xml jar is there.  I
assume we're talking the iText xml jar...

Here's my command line from the class:

D:\jdev9031\jdk\bin\javaw.exe -ojvm -classpath D:\My
Projects\casims\iText\classes;D:\casims\lib;D:\jdev9031\jdev\lib\jdev-rt
.jar;D:\casims\lib\itext-1.01.jar;D:\casims\lib\sax.jar;D:\casims\lib\it
ext-xml-1.01.jar mypackage4.Class1 

It still gives the java.lang.NoClassDefFoundError:
com.lowagie.text.html.HtmlParser error. :/

Thanks,

~~
Chris Dunstall
Analyst Programmer
 
Admin Computing
Bathurst Campus
Charles Sturt University
 
E-Mail:  [EMAIL PROTECTED]
Phone:   +61 2 63384818
Fax: +61 2 63384181
Mobile:  +61 0438 324 180
~~


-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Matt
Benson
Sent: Wednesday, 14 January 2004 3:33 AM
To: Dunstall, Christopher
Cc: itext-questions
Subject: RE: FW: [iText-questions] HTML to PDF Question...


keep the list copied!  :)

Now, as to your last Exception, it just looks the like
xml jar wasn't on the classpath.  I would
double-check.  I ran your Class1 code with the
following test.html:

Related course
structureThe
quick brown fox
jumps overThe quick pink fish jumps over
the dolphin's
nose

and got an error about the BR tag; since the
HtmlParser is using an XML parser behind the scenes,
your HTML apparently needs to be X(well-formed)HTML.
When I changed to:

Related course
structureThe
quick brown fox
jumps overThe quick pink fish jumps over
the dolphin's
nose

I still got a bad PDF.  I added  and  tags
around the content and got a good PDF.  So apparently
the SAXmyHtmlHandler doesn't like HTML document
fragments.

-Matt


--- "Dunstall, Christopher" <[EMAIL PROTECTED]>
wrote:
> Ok, I've got right back to basics and started a
> brand new project with
> nothing in my classpath, the latest version of itext
> and itext-xml
> 
> I have all libraries set, and I run the example
> program from the
> tutorial...
> 
> D:\jdev9031\jdk\bin\javaw.exe -ojvm -classpath D:\My
>
Projects\casims\iText\classes;D:\casims\lib;D:\jdev9031\jdev\lib\jdev-rt
>
.jar;D:\casims\lib\itext-1.01.jar;D:\casims\lib\sax.jar;D:\casims\lib\it
> ext-xml-1.01.jar mypackage4.Class1
> Chapter 7 example 7: parsing the HTML from example 2
> 
> java.lang.NoClassDefFoundError: com.lowagie.text.html.HtmlParser
> void mypackage4.Class1.main(java.lang.String[])   
> Class1.java:49 Exception in thread main
> Process exited with exit code 1.
> 
> Mate, this has got me stumped... I don't exactly
> want to write my own
> HTML to pdf converter :P I've attached the class
> source, as you will see
> it's exactly the same as the tutorial...
> 
> ~~
> Chris Dunstall
> Analyst Programmer
>  
> Admin Computing
> Bathurst Campus
> Charles Sturt University
>  
> E-Mail:  [EMAIL PROTECTED]
> Phone:   +61 2 63384818
> Fax: +61 2 63384181
> Mobile:  +61 0438 324 180 ~~~~~~
> 
> 
> -Original Message-
> From: Matt Benson [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, 13 January 2004 10:01 AM
> To: Dunstall, Christopher
> Cc: itext-questions
> Subject: RE: FW: [iText-questions] HTML to PDF
> Question...
> 
> 
> I would be suspicious of your CLASSPATH and anything
> else strange in your environment, including the
> little
> man in the hat behind you... just kidding about that
> last part.
> 
> -Matt
> 
> --- "Dunstall, Christopher" <[EMAIL PROTECTED]>
> wrote:
> > I'm not even using an Oracle XML parser...
> > 
> > That's what I don't get, I don't know how it's
> > getting there.
> > 
> > I even tried the example off the iText website and
> > it also tries to use
> > the oracle xml parser...
> > 
> > ~~
> > Chris Dunstall
> > Analyst Programmer
> >  
> > Admin Computing
> > Bathurst Campus
> > Charles Sturt University
> >  
> > E-Mail:  [EMAIL PROTECTED]
> > Phone:   +61 2 63384818
> > Fax: +61 2 63384181
> > Mobile:  +61 0438 324 180
> ~~
> > 
> > 
> > -Original Message-
> > From: Matt Benson [mailto:[EMAIL PROTECTED]
> > Sent: Tuesday, 13 January 2004 9:31 AM
> > To: Dunstall, Christopher
> > Cc: itext-questions
> > Subject: RE: FW: [iText-questions] HTML to PDF
> > Question...
> > 
> > 
> > The

FW: [iText-questions] HTML to PDF Question...

2004-01-12 Thread Dunstall, Christopher
Title: Message



Anyone? :) Pretty Please? ;)
 
~~
Chris 
Dunstall
Analyst 
Programmer
 
Admin 
Computing
Bathurst 
Campus

Charles Sturt 
University
 
E-Mail:  
[EMAIL PROTECTED]
Phone:   +61 2 63384818
Fax: +61 2 63384181
Mobile:  
+61 0438 324 180
~~

-Original Message-From: 
[EMAIL PROTECTED] 
[mailto:[EMAIL PROTECTED] On Behalf Of 
Dunstall, ChristopherSent: Monday, 12 January 2004 5:33 
PMTo: [EMAIL PROTECTED]Subject: 
[iText-questions] HTML to PDF Question...Importance: 
High
Hi all, I'm in 
urgent need of help.
 
I'm trying to write 
a PDF from information in a database.
 
Two of the fields 
contain HTML, so when I call the HtmlParser it's like this:
 
HtmlParser.parse( 
document, dataObject.getField1() );
 
When I run it, I get 
the following exception:
 
ExceptionConverter: java.net.MalformedURLException: no protocol: 
Related course structureThe 
quick brown fox jumps overThe quick pink fish jumps over the dolphin's 
nose
 void 
oracle.xml.parser.v2.XMLError.flushErrors1()
  XMLError.java:178
 void 
oracle.xml.parser.v2.XMLReader.pushXMLReader(org.xml.sax.InputSource)
  XMLReader.java:211
 void 
oracle.xml.parser.v2.XMLParser.parse(org.xml.sax.InputSource)
  XMLParser.java:146
 void 
oracle.xml.jaxp.JXSAXParser.parse(org.xml.sax.InputSource, 
org.xml.sax.helpers.DefaultHandler)
  JXSAXParser.java:286
 void 
javax.xml.parsers.SAXParser.parse(java.lang.String, 
org.xml.sax.helpers.DefaultHandler)
 void 
com.lowagie.text.html.HtmlParser.go(com.lowagie.text.DocListener, 
java.lang.String)
 void 
com.lowagie.text.html.HtmlParser.parse(com.lowagie.text.DocListener, 
java.lang.String)
 
Does anyone know 
what it means by no protocol?
 
Thanks in 
advance.
 
~~
Chris 
Dunstall
Analyst 
Programmer
 
Admin 
Computing
Bathurst 
Campus

Charles Sturt 
University
 
E-Mail:  
[EMAIL PROTECTED]
Phone:   +61 2 63384818
Fax: +61 2 63384181
Mobile:  
+61 0438 324 180
~~
 


[iText-questions] HTML to PDF Question...

2004-01-11 Thread Dunstall, Christopher
Title: Message



Hi all, I'm in 
urgent need of help.
 
I'm trying to write 
a PDF from information in a database.
 
Two of the fields 
contain HTML, so when I call the HtmlParser it's like this:
 
HtmlParser.parse( 
document, dataObject.getField1() );
 
When I run it, I get 
the following exception:
 
ExceptionConverter: java.net.MalformedURLException: no protocol: 
Related course structureThe 
quick brown fox jumps overThe quick pink fish jumps over the dolphin's 
nose
 void 
oracle.xml.parser.v2.XMLError.flushErrors1()
  XMLError.java:178
 void 
oracle.xml.parser.v2.XMLReader.pushXMLReader(org.xml.sax.InputSource)
  XMLReader.java:211
 void 
oracle.xml.parser.v2.XMLParser.parse(org.xml.sax.InputSource)
  XMLParser.java:146
 void 
oracle.xml.jaxp.JXSAXParser.parse(org.xml.sax.InputSource, 
org.xml.sax.helpers.DefaultHandler)
  JXSAXParser.java:286
 void 
javax.xml.parsers.SAXParser.parse(java.lang.String, 
org.xml.sax.helpers.DefaultHandler)
 void 
com.lowagie.text.html.HtmlParser.go(com.lowagie.text.DocListener, 
java.lang.String)
 void 
com.lowagie.text.html.HtmlParser.parse(com.lowagie.text.DocListener, 
java.lang.String)
 
Does anyone know 
what it means by no protocol?
 
Thanks in 
advance.
 
~~
Chris 
Dunstall
Analyst 
Programmer
 
Admin 
Computing
Bathurst 
Campus

Charles Sturt 
University
 
E-Mail:  
[EMAIL PROTECTED]
Phone:   +61 2 63384818
Fax: +61 2 63384181
Mobile:  
+61 0438 324 180
~~
 


FW: [iText-questions] PDF: Table Borders

2004-01-04 Thread Dunstall, Christopher
Does no one know?

Chris


-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of
Dunstall, Christopher
Sent: Wednesday, 24 December 2003 12:49 AM
To: [EMAIL PROTECTED]
Subject: [iText-questions] PDF: Table Borders


Hi all,
 
I hope someone's come across this one before...
 
In a PDF, I want to have a table with no border...  I've tried the
Table.setBorder method with Rectangle.NO_BORDER but it doesn't seem to
have any affect.  Anyone have any insight on how to get around this?
 
I have version 1.01 of iText (the one available for download through
HTTP).
 
Thanks in advance...
 
Chris Dunstall



---
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id78&alloc_id371&op=click
___
iText-questions mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/itext-questions


[iText-questions] PDF: Table Borders

2003-12-23 Thread Dunstall, Christopher
Hi all,
 
I hope someone's come across this one before...
 
In a PDF, I want to have a table with no border...  I've tried the Table.setBorder 
method with Rectangle.NO_BORDER but it doesn't seem to have any affect.  Anyone have 
any insight on how to get around this?
 
I have version 1.01 of iText (the one available for download through HTTP).
 
Thanks in advance...
 
Chris Dunstall
N¬HYÞéX¬²š'²ŠÞu¼ˆÂâžìSºÚ+‰©lç(™æ§{^®Ø,ƒT^ŠãºËl…ªéz|¨º»$ŠYlJ('º—èL°ZÞx¸§»îâj[yªçz÷«ÊØbžë¢kay¶¬†È^–[h³+vh§
Xœ’z0†ÛiÿöÊ&ý§bw]»ñ©e¡Èß~õ¢—%‰É"Mìmªç*'²f¢–)à–+-‰7±¶«ž²ØžÉb²Û,¢êÜyú+éÞm¦Ïÿ–+-²Ê.­Ç¢¸ë–+-³ùb²Ø~âµìmªç*'