Skip to content
本页内容

InchesToPoints (方法)

将度量单位从英寸转换为磅 (磅:指打印的字符的高度的度量单位。1 磅等于 1/72 英寸,或大约等于 1 厘米的 1/28。)。

参数

属性数据类型必填说明
Inchesfloat必填指定要转换为磅值的英寸值。

返回值

float

示例

python
#本示例将工作表 Sheet1 中的左边距设为 2.5 英寸
def test():
    Worksheets.Item("Sheet1").PageSetup.LeftMargin = Application.InchesToPoints(2.5)
python
#本示例将4英寸转换为磅值并显示
def test():
    print(Application.InchesToPoints(4))