In the example how do I give 3 different values to the width of three columns ?
And 'you can not display a column ?
// create table
dim ColumnCount as integer = Listbox1.ColumnCount
dim tbl as DynaPDFTableMBS = pdf.CreateTable(3, ColumnCount, 500.0, 100.0)
call tbl.SetBorderWidth(-1, -1, 1.0, 1.0, 1.0, 1.0)
call tbl.SetGridWidth( 1.0, 1.0)
call tbl.SetGridHorizontalColor(100, 100, 100)
call tbl.SetGridVerticalColor(100, 100, 100)
call tbl.SetBorderColor(-1, -1, 100, 100, 100)
// add header row
dim rowNum as integer = tbl.AddRow
call tbl.SetFlags rowNum, -1, tbl.ktfHeaderRow
for i as integer = 0 to ColumnCount-1
call tbl.SetCellText rowNum, i, pdf.ktaLeft, tbl.kcoCenter, Listbox1.Heading(i)
next
// now fill all the cells
dim c as integer = Listbox1.ListCount-1
for Row as integer = 0 to c
rowNum = tbl.AddRow
for Column as integer = 0 to ColumnCount-1
// which alignment for this cell?
dim AlignMent as integer = pdf.ktaLeft
Select case Listbox1.ColumnAlignment(column)
case Listbox1.AlignCenter
AlignMent = pdf.ktaCenter
case Listbox1.AlignRight
AlignMent = pdf.ktaRight
end Select
call tbl.SetCellText rowNum, Column, AlignMent, tbl.kcoCenter, Listbox1.Cell(row, Column)
next
next
// Draw the table now
call pdf.Append
call tbl.DrawTable(50.0, 50.0, 742.0)
while tbl.HaveMore
call pdf.EndPage
call pdf.Append
call tbl.DrawTable(50.0, 50.0, 742.0)
wend
call pdf.EndPage