返回一个
GroupShapes 对象,该对象代表指定图形组中的单个图形。只读。
语法
表达式.GroupItems
表达式 一个代表 Shape
对象的变量。
说明
该属性应用于代表组合图形的 Shape 对象。使用 GroupShapes 对象的 Item
方法可从图形组中返回单个图形。
示例
本示例向 myDocument 中添加三个三角形,并组合这些三角形,为整个图形组设置颜色,然后又独立地更改第二个三角形的颜色。
示例代码 |
let myShapes = ActiveDocument.Shapes
myShapes.AddShape(msoShapeIsoscelesTriangle, 10, 10, 100, 100).Name = "shpOne"
myShapes.AddShape(msoShapeIsoscelesTriangle, 150, 10, 100, 100).Name = "shpTwo"
myShapes.AddShape(msoShapeIsoscelesTriangle, 300, 10, 100, 100).Name = "shpThree"
let gruopShapes = myShapes.Range(["shpOne", "shpTwo", "shpThree"]).Group()
gruopShapes.Fill.PresetTextured(msoTextureBlueTissuePaper)
gruopShapes.GroupItems.Item(2).Fill.PresetTextured(msoTextureGreenMarble)
|