SpreadJS Documentation
Creating Multiple Selections

You can create multiple selections.

Using Code

This example creates multiple selections.

JavaScript
Copy Code
$(document).ready(function () {
    var spread = new GcSpread.Sheets.Spread($("#ss").get(0),{sheetCount:3});
    var sheet = spread.getActiveSheet();

    //Allow selection of multiple ranges
    sheet.selectionPolicy(GcSpread.Sheets.SelectionPolicy.MultiRange);

    //Create two different selection ranges.
    sheet.addSelection(0, 0, 2, 2);
    sheet.addSelection(3, 3, 2, 2);
});
See Also

Developer's Guide

 

 


Copyright © GrapeCity, inc. All rights reserved.

Send comments on this topic.