Table.IsBroken and Table.IsRowBroken

I am creating a table on a pdf document using IsBroken=False and IsRowBroken=False. If the table has to many rows to fit on one page, the whole table is being moved to the second page (leaving the first page blank) and the bottom rows are shown overlapping each other.

What I need is for the table to fill the first page and continue onto the second page if there are to many rows to appear on one page.

I saw another post that had a similar problem, so I downloaded the suggested fix but I am still getting the same issue.

Thanks

Some code so that you can see what I mean:

Dim pdf1 As Pdf = New Pdf()
Dim sec1 As Section = pdf1.Sections.Add()
Dim table1 As Aspose.Pdf.Table = New Aspose.Pdf.Table()
sec1.Paragraphs.Add(table1)
table1.ColumnWidths = “50 50 50 50 50 50 50 50 50 50 50 50”
table1.IsBroken = false
table1.IsRowBroken = false
dim r
dim c
for r = 1 to 100
Dim row As Row
Dim cell As Cell
row = table1.Rows.Add()
for c = 1 to 12
cell = row.Cells.Add(“Cell”)
cell.Border = New BorderInfo(CType(BorderSide.All, Integer), 0.5)
next c
next r
pdf1.Save(…)

Dear rembo,

Thanks for your consideration.

Since you want the table to fill the first page and continue onto the second page if there are to many rows to appear on one page, you should set the IsBroken to true. IsBroken=false means the table will not break when it cann’t be displayed in one page but be moved to the following page.

Thanks for the quick response.

I did try setting Table.IsBroken to true but got an error claiming the table is to large.

System.ApplicationException: The table is too large.

Any ideas?

Thanks

Dear rembo,

Thanks for your consideration.

You got this exception because the table width is larger than the page width(margins excluded). I have added the following line and then it worked well:

sec1.PageInfo.PageWidth = 800

That did it, thanks for your help