HtmlTable

概述

HtmlTable 是 Aspose.Cells FOSS 中用于 TypeScript 的一个类.

此类为 TypeScript 程序中的 HtmlTable 对象声明了 10 个方法。可用的方法包括:addHeader、addRow、constructor、getCellStyle、mergeTables、parse、parseAll、setCssClasses、toHtml、toWorksheet。公共成员在安装 Aspose.Cells FOSS for TypeScript 包后,可供任何 TypeScript 应用程序访问。属性:caption、colWidths、color、cols、count、headers,以及另外 6 项.

属性

名称类型访问描述
cols: number读取获取 cols。
count: number读取获取计数。
height: number读取获取高度。
caption`stringundefined`读取
headersstring[]读取获取表头。
rowsstring[][]读取获取行。
colWidthsnumber[]读取获取列宽。
rowHeightsnumber[]读取获取行的高度。
hiddenRowsboolean[]读取获取隐藏的行。
picturesPictureInfo[]读取获取图片。
style: string读取获取样式。
color: string读取获取颜色。
style: string读取获取样式。
color: string读取获取颜色。

方法

签名描述
constructor(caption: string)在此 HtmlTable 实例上调用 constructor(caption)。
setCssClasses(classes: Map<string, CellStyle>)设置 css 类的值。
getCellStyle(row: number, col: number) → `CellStyleundefined`
addHeader(header: string)在此 HtmlTable 实例上调用 addHeader(header)。
addRow(row: string[])在此 HtmlTable 实例上调用 addRow(row)。
parseAll(html: string, cssClasses: Map<string, CellStyle>) → HtmlTable[]在此 HtmlTable 实例上调用 parseAll(html, cssClasses)。
toWorksheet(worksheet: Worksheet, options: HtmlParseOptions)在此 HtmlTable 实例上调用 toWorksheet(worksheet, options)。
parse(html: string, cssClasses: Map<string, CellStyle>) → HtmlTable在此 HtmlTable 实例上调用 parse(html, cssClasses)。
mergeTables(tables: HtmlTable[]) → HtmlTable在此 HtmlTable 实例上调用 mergeTables(tables)。
toHtml(options: HtmlSaveOptions) → string在此 HtmlTable 实例上调用 toHtml(options)。

另请参阅

 中文