Is there a way to get Worksheet from the Cell in Aspose Cells?
I'm looking for something like myCell.Parent
or myCell.Worksheet
to get the Worksheet
object of a Cell
in Aspos开发者_JS百科e cells for .net. I didn't see any property on the Cell
class that refers the Worksheet
. Wondering if there is a way that I missed?
Using the latest versions of Aspose.Cells for .NET (e.g Aspose.Cells for .NET v5.3.2 etc.) now, it is possible to get the parent worksheet from the cell object. You may simply use Cell.Worksheet property.
I've also asked in the Aspose Forum. It's not possible yet, but the added my request as new feature request.
Convert or cast cell to Range and then you can find the Worksheet property:
Excel.Range myRange = (Excel.Range) myCell;
Excel.WorkSheet myWS = null;
if ( myCell != null ) {
myWS = myRange.WorkSheet;
}
精彩评论