We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

PdfLightTable column width problem after upgrading the version


we have been using old syncfusion version to create pdf documents containing a PdfLightTable. We set the Width on all PdfColumn. If there are too many the sum might be bigger than PageSettings.Width that we set on our PdfDocument. However version managed to autosize the columns so all have been displayed (see attached screenshot).

Now we updated to syncfusion version but it does not resize the column width automatically anymore. Columns now are moved out of the visible area (to the right). How can we enforce's behavior?

If we do not set any column width then each column width is evenly sized and displayed with However we would like to keep the behavior of as it at least considers bigger/smaller width columns and does not evenly resize all columns to have the same width.

Please advise what to do.

Thanks, Tobi

Attachment: Desktop_56f008e5.zip

6 Replies

TK Tobias Koehn July 10, 2019 07:37 AM

We went back to version but are facing the same problem

SL Sowmiya Loganathan Syncfusion Team July 11, 2019 08:01 AM

Hi Tobias,  

We have checked with the sample to draw table by setting column width (which exceeds the page width) in both product version and Effect from version, the specified width will be allocated for the columns. But in earlier (before v15.3.0.26) even in the specification of column width, these are equally shared based on the page width. Please refer the below release notes for breaking changes from below,  

However recently we have exposed API to create table as like in old product version ( Please find the below code snippet for more details, 
// Create a PdfLightTable 
PdfLightTable pdfLightTable = new PdfLightTable(); 
// To update table column width size based on PdfLightTable width size  
pdfLightTable.ColumnProportionalSizing = true;  
Note: This property will not include the product version This is effectively available only from the product version  
Kindly try the above solution in your end and let us know if it satisfies your requirement.  

Sowmiya L 

TK Tobias Koehn July 11, 2019 11:43 AM

Thanks works!

SL Sowmiya Loganathan Syncfusion Team July 12, 2019 01:45 AM

Hi Tobias, 

We glad to know that your issue is resolved. 

Sowmiya L 

ER Eduardo Rojas replied to Tobias Koehn March 23, 2020 03:35 PM

Thanks works!

Hi, what do we do for portable versions? 
The portable version:
Syncfusion.Pdf.Portable, Version=15.2120.0.40, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89
does not appear to have this property.

SL Sowmiya Loganathan Syncfusion Team March 24, 2020 05:30 AM

Hi Eduardo,    
The property “ColumnPropotionalSizing” creates the table as in the old product version (before v15.3.0.26) and available only from the product version in the ASP.NET Core platform. Please refer the below release notes for more details,    
Note: We have noticed in your update and found that you have used the product version and by default, the table has been created as like the old version (even in the specification of column width, these are equally shared based on the page width).   
Please let us know if you need any further assistance with this.   
Sowmiya Loganathan 

Live Chat Icon For mobile
Up arrow icon