sheets.rows.cells.borderTop Object

The style information for the top border of the cell.

sheets.rows.cells.borderTop.color String

The top border color of the cell.

Many standard CSS formats are supported, but the canonical form is "#ccff00".

sheets.rows.cells.borderTop.size Number

The width of the border in pixels.

The allowed values are:

  • 1 - Results in a "thin" border.
  • 2 - Results in a "medium" border.
  • 3 - Results in a "thick" border.

Example - add a top border to the cell

<script>
var workbook = new kendo.ooxml.Workbook({
sheets: [
 {
     rows: [
       { cells: [ { value: "Border", borderTop: { color: "#ff0000", size: 3 } } ] }
     ]
 }
]
});
kendo.saveAs({
dataURI: workbook.toDataURL(),
fileName: "Test.xlsx"
});
</script>
In this article
Not finding the help you need? Improve this article