I'm wanting to be able to select multiple cells on a row but not next to each other using the ctrl key. This works fine but I'm not sure how to then access the selected cells in code.
When using the GetLastSelection() in the MouseUp event, it only has access to the last cell selected.
Well, I am afraid, obtaining the non continuous ranges of selected cells feature is not available. I have logged your feature request into our issue tracking system with an issue id: CELLSNET-16008. We will inform your if there is any update about it.
We have implemented a method named “GetAllSelectedRanges”
to get all selected CellRange objects returned by an ArrayList object in
Aspose.Cells.GridDesktop v2.1.0.2004(attached). Please try these
lines of code for your need accordingly:
ArrayList ar =
gridDesktop1.Worksheets[0].GetAllSelectedRanges();