We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Griddesktop I am losing styles on file export

I am losing cell style when I export out of grid desktop.


Thanks for providing some details.

Please create a sample Winform application with our latest Aspose.Cells.GridDesktop v8.5.2 (you may download Aspose.Cells for .NET v8.5.2 package from Downloads module and install on your pc to get the latest version of Aspose.Cells.GridDesktop v8.5.2), zip it and post us here to reproduce the issue on our end, we will check it soon. Also provide your your template Excel file(s) if there is any. This will help us really evaluate your issue properly to consequently figure it out soon.

Thank you.

Here is the test project. I’ve included the saved excel spreadsheet.


Thanks for your posting and using Aspose.Cells.GridDesktop.

We were able to observe this issue and found yellow color cell does not get exported. We have also tried foreground color and simply color property but it did not work.

We have logged this issue in our database for investigation. We will look into it and fix this issue. Once the issue is resolved or we have some other update for you, we will let you know asap.

This issue has been logged as

  • CELLSNET-43859 - Cell filled with Yellow color does not get exported to XLSX file


Thanks for using Aspose.Cells.GridDesktop.

We have fixed this issue and will provide it to you soon.

Please see the following code and comments for your reference.

//I have added style.Pattern propertie to fix this issue.
//thus the behavior is exactly like in MS-EXCEL
//the default Pattern is none, so we need to set Pattern and ForegroundColor ,to get the expected effect
//ForegroundColor/BackgroundColor will take effect when the Pattern is not none
Style style = gridDesktop1.Worksheets[0].Cells[0, 0].GetStyle();
style.Pattern = GridBackgroundType.Solid;
style.ForegroundColor = Color.Yellow;
gridDesktop1.Worksheets[0].Cells[0, 0].SetStyle(style);

The issues you have found earlier (filed as CELLSNET-43859) have been fixed in this update.

This message was posted using Notification2Forum from Downloads module by Aspose Notifier.