Hi,
You have caught me right. My design in not optimal. But I am restricted
by the following
I am not creating the Document object from the scratch(So I am not using
document.add()). I will get a input pdf stream which is generated after
filling the acrobat FDF field and then flattening it. I then copy this
pdf stream using writer.getImportedPage() to the new Document object so
that I can bring the contents into Document object. I need Document
object because I want to say document.newPage when table gets bigger
than the page.

I need to continue from here and add some dynamic table which can have
any number of rows.

As you pointed out, I can now start a new page based on the return value
from writeSelectedRows.

Thanks
Ashwani




-----Original Message-----
From: Bruno Lowagie [mailto:[EMAIL PROTECTED]
Sent: Friday, January 13, 2006 3:20 PM
To: Kalra, Ashwani
Cc: [email protected]
Subject: Re: [iText-questions] retrieving the position of last text
written

Kalra, Ashwani wrote:

> Hi,
> I am trying to figure out the solution for the following problem.
> I will get a pdf Stream and I have to start writing  a table at
> absolute position on this pdf(using table.writeSelectedRows)

writeSelectedRows returns an Y-coordinate.

> Is there any way I can find out where  the contents of the current pdf

> have ended(ie the position) so that I can start my table after that.

Maybe you could pass the result of writer.getVerticalPosition to a page
event.
I don't know if this is good advice or bad advice, as the question is
very vague.

> Also how to know if the page is getting to an end   while writing a
> big table?

Your questions give the impression that your design isn't really
optimal.
Maybe you should look at your problem from a different angle.
I think changing your design will solve most of your questions.
br,
Bruno

This message contains information that may be privileged or confidential and is 
the property of the Capgemini Group. It is intended only for the person to whom 
it is addressed. If you are not the intended recipient,  you are not authorized 
to read, print, retain, copy, disseminate,  distribute, or use this message or 
any part thereof. If you receive this  message in error, please notify the 
sender immediately and delete all  copies of this message.



-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://ads.osdn.com/?ad_idv37&alloc_id865&op=click
_______________________________________________
iText-questions mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/itext-questions

Reply via email to