iTextSharp table width 100% of page

前端 未结 5 1661
小蘑菇
小蘑菇 2021-02-12 12:14

I\'m trying to add a table to a document using iTextSharp. Here is an example:

Document document = new Document(PageSize.LETTER,72, 72, 72, 72);
PdfWriter writer         


        
5条回答
  •  旧时难觅i
    2021-02-12 12:50

    The WidthPercentage property is no longer available in iText7. Use the following instead

    table.SetWidth(new UnitValue(UnitValue.PERCENT, 100));
    

提交回复
热议问题