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

Free Support Forum - aspose.com

SaveToExcelFile saves headers as hyperlinks if column sorting is enabled

When I save a web grid worksheet using .SaveToExcel, the excel file has hyperlinks in row 1 where column headers are saved. This seems to happen when"Enable Sort" property is on; the hyperlink column has the following address “cellcmd:_BCSORT%235”, where the number after the BCSORT varies for each column; seems like a hyperlink to your sort. See a sample in the attachement


Thanks for the sample file.

We have noticed the issue, we will look into it soon. I have logged your issue into our issue tracking system with an id: CELLSNET-20103.

Thank you.

<!–[if gte mso 10]> /* Style Definitions */ table.MsoNormalTable {mso-style-name:"Table Normal"; mso-tstyle-rowband-size:0; mso-tstyle-colband-size:0; mso-style-noshow:yes; mso-style-priority:99; mso-style-parent:""; mso-padding-alt:0in 5.4pt 0in 5.4pt; mso-para-margin:0in; mso-para-margin-bottom:.0001pt; mso-pagination:widow-orphan; font-size:10.0pt; font-family:"Times New Roman","serif";}



We have fixed the issue in Aspose.Cells.GridWeb v2.3.2.2002 (attached). The "Sort" command should not be exported into excel file now.

In this fix, for your knowledge, some properties are obsolete, so you may adjust your codes accordingly if needed.

1) The properties of NumberType, Custom and IsLocked in Aspose.Cells.GridWeb.Data.WebCell are obsolete. These properties are added into Aspose.Cells.GridWeb.TableItemStyle.Style.

2) The property of Style in Aspose.Cells.GridWeb.Data.WebCell is obsolete. The recommended alternatives methods are Aspose.Cells.GridWeb.Data.WebCell.GetStyle() and SetStyle().

Thank you.

<span style=“font-size: 10pt; font-family: “SimSun”,“serif”;”>

Got the headers OK, but now the export includes 2 worksheets, 1 blank worksheet (sheet1), and a second, named worksheet with my data. Also, not sure why, the header row style (color) is inconsistent; see attachment for snapshots of both issues


I can find the extra sheet issue. But, could you create a sample application to show the style(color) issue, we will check your issue soon.

Thank you.

Unfortunately, our development environment is not a straight ASP.NET and it would take relatively long for me to create a sample app. But, if my suspicions are correct (based on visual observations), header cell style appears to be taken from a cell to the left and below (i.e. header cell C3 would get style from B2). This kind of makes sense as you really don’t have the style for the header row, you are getting that configured through the sheet style/template. But when exporting to Excel, you need to get it from somewhere. I’d suggest to get the style from the cell immediately below. In our case, we use different style for read only verses/RW cells, so that is why you see gray background (read only) on some columns and normal white background on others. If headers followed the same style/that would be OK. Ideally, there would be a separate style property for the header cell row.

In addition, headers entered as HTML with embedded line breaks (
) are exported as plain text, so the header ends showing something line “Vendor
Part No”, while in the grid the
is properly interpreted and shows as a 2 line string


Thanks for providing us further details.

We will look into it soon.

We also appreciate if you could create a simple project to show the issue, this will help us really to figure out your issue soon.

Thank you.


Please try the attached version Aspose.Cells.GridWeb v2.3.2.2003. We have fixed the bug of exporting an additional worksheet. And, you can set multi-header with “Vendor\nPart No” for your need.

Moreover, we still could not find and evaluate how to reproduce the style issue you mentioned. Please provide us a sample project to reproduce the issue.

Thank you.

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

This message was posted using Notification2Forum from Downloads module by aspose.notifier.