API Documentation > CorelDRAW > 2025-v26 > ShapeRange > IVGShapeRange
ShapeRange.AddRange method
Adds a shape range into a range
Syntax:
Sub AddRange(ByVal ShapeRange As ShapeRange)
Parameters:
Name Type Description
ShapeRange
Remarks:
The AddRange method adds a specified shape range to the current range.
Examples:
The following VBA example finds all the ellipses and rectangles on a page, and it then fills the shapes with a radial fountain fill.
Sub Test()
Dim sr As ShapeRange
Set sr = ActivePage.FindShapes(Type:=cdrEllipseShape)
sr.AddRange ActivePage.FindShapes(Type:=cdrRectangleShape)
sr.ApplyFountainFill CreateRGBColor(255, 0, 0), CreateRGBColor(255, 255, 0), cdrRadialFountainFill 
End Sub