Mangling of merged cells when deleting cells


#1

I’m having an issue which I strongly suspect is a bug in apose.excel.dll version 3.6.1.0.

I’ve attached a simple C# project which demonstrates the problem.

Given: a spreadsheet with several regions of merged cells (my example worksheets contain 4 such regions each).
Event: I remove a cell or group of (unmerged) cells from a worksheet which has been loaded from an existing excel file. (sample included)
Result: the 4 merged cell areas in the saved worksheet no longer match the position and sizes in original spreadsheet.

I’ve included a copy of a sample spreadsheet, a simple C# file which demonstrates the problem, and the corresponding project file. I did not include a copy of our license file in this project.

Please let me know if you need any more information. We’re quite pleased with your product! Thankyou!

John Hartman
johnh@shepsys.com


#2

Dear John,

Thank you for the report. However, I didn't find your attached project.

I only need your template file and sample code to figure out the problem.

How do you remove a cell, using DeleteRow or DeleteColumn method? If you used them to remove a cell, the merge cell position or size may be changed. That's same as MS Excel. You can verify it in MS Excel.


#3

Dear Laurence,

I’m sorry about not attaching the sample earlier. I’ve resent it with this email, as a zipped file named voidpoint.sample.zip. It contains the webform code which executes my function, along with the excel book I tested with.

I’m actually using DeleteRange, limiting myself to a single cell removal in this sample.

I hope it helps.

-John H.


#4

Hi John,

Yes. This is a bug. I fixed it. Please try this attached version.