Skip to content
本页内容

Type (属性)

返回或设置一个 MsoConnectorType 值,它代表连接符格式类型。

示例

python
#本示例将第一张工作表中第三个形状(连接符)格式类型设置为直线
def test():
    shapes = Application.Worksheets.Item(1).Shapes
    shape = shapes.Item(3)
    shape.ConnectorFormat.Type = msoConnectorStraight
python
#本示例显示活动工作表中第四个形状(连接符)的格式类型是否为曲线
def test():
    shapes = ActiveSheet.Shapes
    shape = shapes.Item(4)
    print(shape.ConnectorFormat.Type == msoConnectorCurve)