SpreadJS Documentation > Sample Code > Sample Code for Cells > Setting a Background Image |
You can specify a background image for a cell.
This example sets an image in the cell.
JavaScript |
Copy Code
|
---|---|
$(document).ready(function () { var spread = new GcSpread.Sheets.Spread($("#ss").get(0),{sheetCount:3}); var activeSheet = spread.getActiveSheet(); //Set backgroundImage to cell(1,1). activeSheet.getCell(1, 1).backgroundImage("Image file path name"); }); |