Drill-through formulas not returning correct precedent sheets

“Drill-through” formulas that look at multiple sheets e.g.

=HSTACK(Sheet2:Sheet4!R[-3]C)
=SUM(Sheet2:Sheet4!R[-3]C)

Have the incorrect precedents set on them in .net. In these cases the target sheet will be “Sheet2:Sheet4” rather than the correct Sheet2, Sheet3, Sheet4

Thanks

Dan

@TheFish

Could you please provide more details about the specific issue you are encountering with the drill-through formulas? Are you using any specific version of Aspose.Cells?

@TheFish

Are your talking about the result of SheetName? For multiple sheets references, we can only return the expression like what is in the formula expression. For such kind of references, you need to split the sheet name to get corresponding worksheets in the range.

I’m focusing on the Referred Area Class ReferredArea | Aspose.Cells for .NET API Reference that would be returned from GetPrecedents Cell.GetPrecedents | Aspose.Cells for .NET API Reference on a cell containing these formulae.

The SheetName would then be “Sheet2:Sheet4” which isn’t a sheet in the workbook. splitting this by the colon also wouldn’t be correct as the formula refers to all sheets between these two sheets (not just the two sheets). I could write some code that works out all of the sheet names from the workbook between these two sheets after splitting by a colon… I am surprised that the library isn’t doing this natively.

@TheFish

We will also add one Api to provide all sheet names for ReferredArea.

We have opened the following new ticket(s) in our internal issue tracking system and will deliver their fixes according to the terms mentioned in Free Support Policies.

Issue ID(s): CELLSNET-57638

You can obtain Paid Support Services if you need support on a priority basis, along with the direct access to our Paid Support management team.

@TheFish
We add one property for ReferredArea:

ReferredArea.SheetNames

which returns an array of all sheet names that this reference uses.

The new property will become available from our next official version 25.2.

The issues you have found earlier (filed as CELLSNET-57638) have been fixed in this update. This message was posted using Bugs notification tool by johnson.shi