返回指定区域中标题行的行数。Long 类型,只读。
对指定区域使用此属性之前,可用 CurrentRegion 属性找到该区域的边界。
本示例将变量 rTbl
设为活动单元格所在的当前区域,但不包含任何标题行。
Set rTbl = ActiveCell.CurrentRegion
' remove the headers from the range
iHdrRows = rTbl.ListHeaderRows
If iHdrRows > 0 Then
' resize the range minus n rows
Set rTbl = rTbl.Resize(rTbl.Rows.Count - iHdrRows)
' and then move the resized range down to
' get to the first non-header row
Set rTbl = rTbl.Offset(iHdrRows)
End If