HotXLS 文件

LineStyle 屬性

傳回或設定框線的線條樣式。可讀寫 LongWord

語法

property LineStyle: LongWord;

說明

LineStyle 可為下列 XlLineStyle 常數之一
xlContinuous
xlDash
xlDashDot
xlDashDotDot
xlDot
xlDouble
xlSlantDashDot
xlLineStyleNone

範例

此範例在 A1:C5 範圍周圍新增框線

Workbook.Sheets[1].Range['A1', 'C5'].Borders[xlEdgeTop].LineStyle := xlDot;
Workbook.Sheets[1].Range['A1', 'C5'].Borders[xlEdgeRight].LineStyle := xlDot;
Workbook.Sheets[1].Range['A1', 'C5'].Borders[xlEdgeBottom].LineStyle := xlDot;
Workbook.Sheets[1].Range['A1', 'C5'].Borders[xlEdgeLeft].LineStyle := xlDot;
此範例與前一個相同

Workbook.Sheets[1].Range['A1', 'C5'].Borders.LineStyle := xlDot;