# getRealColIndexByColLabel-按列名获取相对列索引
调用getRealColIndexByColLabel函数按列标签获取该列在该区域内的索引。
最小支持版本:5.0.0
# 接口说明
已打开的工作簿对象,详情请参见open (opens new window)。
已获取工作表对象,详情请参见getSheetByName (opens new window)。
已获取区域对象,详情请参见getRange (opens new window)。
# 语法
<ExcelRange object>.getRealColIndexByColLabel(<label>)
1
<ExcelRange object>.按列名获取相对列索引(<label>)
1
# 函数类型
实例函数
# 请求参数
参数名称 | 类型 | 是否必选 | 默认值 | 示例值 | 描述 |
---|---|---|---|---|---|
label | Cube.Lang.String | 是 | 无 | "A" | 列标签。 |
# 返回参数
参数名称 | 类型 | 示例值 | 描述 |
---|---|---|---|
Result | Cube.Lang.Number | 1.0 | 列标签索引。 |
# 请求示例
区域对象.getRealColIndexByColLabel("A")
1
最近更新时间: {
"value": "2023-09-12",
"effect": true
}