[]
        
首页
开发者学堂
文档
论坛
市场
生态机会
活动
立即试用
(Showing Draft Content)

GC.Spread.Sheets.Comments.CommentManager

Class: CommentManager

Sheets.Comments.CommentManager

Table of contents

Constructors

Methods

Constructors

constructor

• new CommentManager(sheet)

表示可以管理工作表中所有批注的批注管理器。

Parameters

Name Type Description
sheet Worksheet 工作表。

Methods

add

▸ add(row, col, text): Comment

为指定行列的单元格添加批注。

Parameters

Name Type Description
row number 单元格的行索引。
col number 单元格的列索引。
text string 批注的文本。

Returns

Comment

已添加到单元格的批注。


all

▸ all(): Comment[]

获取工作表中的所有批注。

Returns

Comment[]


clear

▸ clear(range): void

清除工作表中指定范围内的所有批注。当未指定范围时,将清除工作表中的所有批注。

Parameters

Name Type Description
range Range 要清除所有批注的范围。

Returns

void


get

▸ get(row, col): Comment

获取指定行列单元格中的批注。

Parameters

Name Type Description
row number 单元格的行索引。
col number 单元格的列索引。

Returns

Comment

指定单元格中的批注。


remove

▸ remove(row, col): void

移除指定行列单元格中的批注。

Parameters

Name Type Description
row number 单元格的行索引。
col number 单元格的列索引。

Returns

void