Problem with border style

Good day!

I’m using Aspose.Cells 22.6 for Java and I have a trouble with one particular case of borders styles.
If you open borders properties of D2 cell in file workbook.xlsx, you will see that left border exists.

But when I get this cells left border line style in Aspose it returns me zero.
And when I get left border line style of cell H2 in Aspose it returns me 1 as expected.

Simple test for this case is applied.
Could you get look at it?

border_style.zip (8.3 KB)

@nikiton,

Please notice, after an initial test, I am able to reproduce the issue as you mentioned by using the following sample code with your template file. I found the issue with border (line) style for the D2 cell.
e.g.
Sample code:

Workbook workbook = new Workbook("f:\\files\\workbook.xlsx");
Worksheet worksheet = workbook.getWorksheets().get(0);
//Cell cell = worksheet.getCells().get(1, 7);//1
Cell cell = worksheet.getCells().get(1, 3);//0
System.out.println(cell.getDisplayStyle().getBorders().getByBorderType(BorderType.LEFT_BORDER).getLineStyle());

I have logged a ticket with an id “CELLSJAVA-44717” for your issue. We will look into it soon.

Once we have an update on it, we will let you know.

Thanks a lot!

@nikiton,

You are welcome.

@nikiton,

We evaluated your issue in details. It is not an issue of our component. In fact the left border of D2 you saw in MS Excel is the right border of B2. The column C is hidden in the template file, so if you make this column visible, you will see there is no left border for D2 cell, and neither for right border of C2. You also may check the style settings of cell D2 in MS Excel, the border settings also show that D2 has no left border

@nikiton,
After investigate the border settings in the template file further, we found there is an issue of checking borders for adjacent cells. We will fix the issue soon.

@nikiton,

We are pleased to inform you that your issue has been resolved. The fix will be included in our upcoming release: Aspose.Cells for Java v22.7, which is scheduled to be published within 1-2 days or so.

Okay, this is the good news )

The issues you have found earlier (filed as CELLSJAVA-44717) have been fixed in this update. This message was posted using Bugs notification tool by Peyton.Xu