API Documentation > CorelDRAW > 2025-v26 > ShapeRange > IVGShapeRange
ShapeRange.AddToPowerClip method
Adds this shape range to a power clip
Syntax:
Sub AddToPowerClip(ByVal Shape As Shape, Optional ByVal CenterInContainer As cdrTriState = cdrUndefined)
Parameters:
Name Type Description
Shape
CenterInContainer
Specifies whether to center the shape range in the PowerClip container.
Remarks:
The AddToPowerClip method adds a shape range to a specified PowerClip container.
Examples:
The following VBA example places 150 randomly-sized and randomly-colored circles inside a text object.
Sub Test()
Dim sr As New ShapeRange
Dim s As Shape, n As Long
For n = 1 To 150
  Set s = ActiveLayer.CreateEllipse2(Rnd() * 4, Rnd() * 2, Rnd() * 0.3)
  s.Fill.UniformColor.RGBAssign Rnd() * 256, Rnd() * 256, Rnd() * 256
  sr.Add s
Next n
Set s = ActiveLayer.CreateArtisticText(0, 0, "Clip")
With s.Text.FontProperties
  .Name = "Arial Black"
  .Size = 150
End With
sr.AddToPowerClip s 
End Sub