跳到主要内容

SetCellBorderRight

设置应在当前表格单元格右侧显示的边框。

语法

expression.SetCellBorderRight(fSize, oApiFill);

expression - 表示 ApiTableCell 类的变量。

参数

名称必需/可选数据类型默认值描述
fSize必需mm当前边框的宽度。
oApiFill必需ApiFill用于填充当前边框的颜色或图案。

返回值

此方法不返回任何数据。

示例

此示例设置应在表格单元格右侧显示的边框。

// How to set cell right border with its fill color.

// Create table and set its cell right border.

const presentation = Api.GetPresentation();
const slide = presentation.GetSlideByIndex(0);

const table = Api.CreateTable(2, 4);
const row = table.GetRow(0);
const cell = row.GetCell(0);
const fill = Api.CreateSolidFill(Api.RGB(51, 51, 51));
cell.SetCellBorderRight(2, fill);

slide.RemoveAllObjects();
slide.AddObject(table);