setSplitRows(true)
setSplitLate(false)

Paulo

----- Original Message ----- 
From: "Nilabhra Banerjee" <[EMAIL PROTECTED]>
To: <itext-questions@lists.sourceforge.net>
Sent: Wednesday, November 01, 2006 4:21 PM
Subject: [iText-questions] I'm at a loss


Hi Everybody,

  I am adding PdfPTable to a document. I want the row contents to spill over 
to next next page if it does not end in same page. I have used the 
setSplitRows(false) given in an example. But I am finding that in the pdf 
document, that the whole row is transferred to the next page.

  How to fix it?

  Given below is the relevant part of the code.

  Thanks and Regards
  Neil
  ...........................
  ...........................
  ...........................

  //setCell and drawLine functions explained at the bottom.

  document.add(tablePat);
  document.add(new Paragraph(""));

  // This is Response Notes.




  document.add(new Paragraph(" "));



  PdfPTable tableResp = new PdfPTable(4);

  // Creating response Notes


  //Adding Heading
  tableResp.addCell(drawLine(4));
  tableResp.addCell(setCell("Response Notes: ", font2, 0, 0, 4));
  tableResp.addCell(drawLine(4));
  DisplayList responseNotes = null;
  ArrayList notesDates = null;
  ArrayList notesValues = null;
  int arraySize = 0;

  responseNotes = referralWebImpl.getResponseNotes();
  // Rendering Response Notes.
  if(responseNotes !=null){
  notesDates = responseNotes.getIds();
  notesValues = responseNotes.getValues();
  arraySize = notesDates.size();

  for(int arrayIndex =0;arrayIndex<arraySize;arrayIndex++)

  {
  String noteDate = (String)notesDates.get(arrayIndex);
  // A variable string, may be small may be very very big.
  String noteValue = (String)notesValues.get(arrayIndex);
  tableResp.addCell(setCell(noteDate, font1, 0,0,1));
  tableResp.addCell(setCell(noteValue, font1, 0,0,3));
  }

  }
  tableResp.setWidthPercentage(100);
  document.add(tableResp);
  // tableResp.setSplitLate(false);
  tableResp.setSplitRows(false);

  document.add(new Paragraph(""));
  ...................................................
  ....................................................

  //Returns a PdfCell with the parameters.
  private PdfPCell setCell(String stringValue, Font font, int alignment, int 
border, int colspan);

  //drawline
  draws a horizontal line within a PdfPcell. Parameter is colspan.



 Send instant messages to your online friends http://uk.messenger.yahoo.com


--------------------------------------------------------------------------------


> -------------------------------------------------------------------------
> Using Tomcat but need to do more? Need to support web services, security?
> Get stuff done quickly with pre-integrated technology to make your job 
> easier
> Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642


--------------------------------------------------------------------------------


> _______________________________________________
> iText-questions mailing list
> iText-questions@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/itext-questions
> 


-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions

Reply via email to