Adding Images, JavaScript Programming Example of Adding Images in SpreadSheet

JavaScript Programming Example of Adding Images in SpreadSheet

You can add an image into a SpreadSheet cell using the addImage method. There are three parameters that you should apply: rowId (number of the row), columnId (number of the column), URL (the URL of an image). Check out a free programming example of how it works below.

JS Code

webix.ready(function(){
  webix.ui({
    view:"spreadsheet",
    id: "ssheet",
    toolbar: "full",
    data:{
      styles: [
        [ "blue", "#FFFFFF;#2244DE;" ]
      ],
      sizes: [
        [ 3, 0, 50 ]
      ],
      data: []
    }
  });

  $$("ssheet").addImage(3,2,"http://docs.webix.com/media/desktop/icons/spreadsheet.png");
});