Mysterious Extra Column in PDF Export

I have a grid using

- Custom Data Adapter

- Custom Agregates

- Template Columns

- Grouping by Defualt

PDF Export Settings

- Custom Columns defined in the PDF  export action to set widths/headers

ExportProperties.DisableAutoFitWidth = true;

ExportProperties.IncludeCommandColumn = false;

ExportProperties.IncludeTemplateColumn = false;

ExportProperties.AllowHorizontalOverflow = false;


When exporting to PDF a mysterious extra column which has no header and no cell value. It looks around 100px wide and has a solid black border appearance which is different to all other columns. It is appened as an overflow onto a second page.

Changing the width value individually of all defined columns seems to have no effect on this column.. 

I have tried removing command columns entirely and it still appears.



3 Replies 1 reply marked as answer

RS Renjith Singh Rajendran Syncfusion Team July 12, 2022 04:42 AM UTC

Hi Daniel,


Greetings from Syncfusion support.


We checked this scenario by creating a sample based on your shared grid scenario. But we could not face the reported issue during pdf exporting. We are attaching a sample in this ticket for your reference.


Kindly download and refer the attached sample. If you are still facing difficulties, then the following details would be helpful for us to further proceed on this scenario.


  1. Share a simple issue reproducing sample based on your scenario.
  2. Or if possible reproduce the problem with the attached sample and share with us for further analysis.
  3. Share the Syncfusion version details.
  4. Share the exact scenario you are facing this problem.
  5. Share the complete grid rendering codes along with model class codes.


The provided information will help us analyze the problem, and provide you a solution as early as possible.


Regards,

Renjith R


Attachment: ServerApp_64fac9c7.zip


DR Daniel Reibelt July 12, 2022 05:35 AM UTC

Hi Renjith


Thanks for the prompt support, I have used your sample and made a few modifications which infact now cause the issue... See attached solution.


Attachment: ServerApp_64fac9c7_Updated_caa34d55.zip


RS Renjith Singh Rajendran Syncfusion Team July 13, 2022 12:00 PM UTC

Hi Daniel,


Thanks for sharing the details.


We have analyzed the shared sample and we could see that you are trying to display the grouped column(which is hidden because of grouping) during pdf exporting. As the ShowGroupedColumn property value of GridGroupSettings is false(by default) it continues to hide the content of the grouped column which is causing the reported behavior.


So based on your scenario we suggest you to enable the ShowGroupedColumn property to display the contents of the grouped column in grid so that the grouped column content will also be displayed in the exported pdf file.


 

<GridGroupSettings Columns="@Initial" ShowGroupedColumn="true"></GridGroupSettings>

 


Please use the above suggestion to overcome the reported scenario.


Regards,

Renjith R


Marked as answer
Loader.
Up arrow icon