@John.He , Can you please have a look at this zip and let me know if the latest version has solved the issue.
TestFile-output-pdf.zip (587.3 KB)
@shreyap
By testing with the newly provided sample files and the following sample code in v25.3, we can still obtain the correct results. Please refer to the attachment. out_net.zip (397.6 KB)
Workbook wb = new Workbook(filePath + "Testfile.xlsx");
ShapeCollection shapes = wb.Worksheets[0].Shapes;
int shapeCount = shapes.Count;
for (int i = 0; i < shapeCount; i++)
{
Shape shape = shapes[i];
shape.Placement = PlacementType.MoveAndSize;
}
wb.Worksheets[0].Cells.DeleteBlankRows();
wb.Save(filePath + "out_net.xlsx");
wb.Save(filePath + "out_net.pdf");
@John.He , I updated my aspose cells version to 25.3 and still not able to fix it.
Please refer to the code, testFile I have used and the output files generated and my expected output.
It is a priority. It would be great if it gets fixed. Thank you.
New folder1.zip (1.4 MB)
Thanks for the template Excel file, sample app and output files.
Thank you for providing the template Excel file, sample application, and output files. I tested your scenario using the template Excel file and sample app, and I discovered the issue. I have recorded the resource files and my findings with your existing ticket “CELLSNET-57838” in our database. The issue remains “Open.” We will assess and investigate the issue soon.
@amjad.sahi ,
@John.He mentioned that with the testing on his/her machine he/she was able to fix the issue. Am I missing something?
I guess this is because he is using a different file and code snippet. However, when I tested your sample app along with the template file from the “New folder1.zip” attachment, I encountered the issue.
@shreyap
By testing on the latest version v25.3 using the following sample code, we found that there are still differences between the result file and the expected result file. Please refer to the attachment. out_net.zip (392.5 KB)
Sorry for any inconvenience caused to you. We will continue to fix the issue and notify you promptly once there are updates.
The sample code as follows:
Workbook wb = new Workbook(filePath + "Testfile.xlsx");
ShapeCollection shapes = wb.Worksheets[0].Shapes;
int shapeCount = shapes.Count;
for (int i = 0; i < shapeCount; i++)
{
Shape shape = shapes[i];
shape.Placement = PlacementType.MoveAndSize;
}
DeleteBlankOptions options = new DeleteBlankOptions();
options.DrawingsAsBlank = false;
wb.Worksheets[0].Cells.DeleteBlankRows(options);
wb.Save(filePath + "out_net.xlsx");
wb.Save(filePath + "out_net.pdf");
We are pleased to inform you that your issue (Ticket ID: “CELLSNET-57838”) has been resolved precisely. The fix/enhancement will be included in the next release (Aspose.Cells v25.4) scheduled for release in the first half of April 2025. You will be notified when the next version is released.
@amjad.sahi,
Glad to hear the update. It was a long pending task. Looking forward to integrate it. Please let me know the release timeline and any code changes that needs to be done in specific.
We plan to release 25.4 in two weeks and you will get notified here when it is published.
We changed the default behavor of shifting shapes when deleting blank rows above them. There is no need to change the code you used currently.
The issues you have found earlier (filed as CELLSNET-57838) have been fixed in this update. This message was posted using Bugs notification tool by leoluo