API Documentation > CorelDRAW > 2025-v26 > Shape > IVGShape
Shape.CreateBlend method
Blends two shapes
Syntax:
Function CreateBlend(ByVal Shape As Shape, Optional ByVal Steps As Long = 20, Optional ByVal ColorBlendType As cdrFountainFillBlendType = cdrDirectFountainFillBlend, Optional ByVal Mode As cdrBlendMode = cdrBlendSteps, Optional ByVal Spacing As Double = 0, Optional ByVal Angle As Double = 0, Optional ByVal Loop As Boolean = False, Optional ByVal Path As Shape = Nothing, Optional ByVal RotateShapes As Boolean = False, Optional ByVal SpacingAccel As Long = 0, Optional ByVal ColorAccel As Long = 0, Optional ByVal AccelSize As Boolean = False) As Effect
Parameters:
Name Type Description
Shape
Steps
Long
Specifies the number of steps.
ColorBlendType
Specifies the color-blend type, and returns cdrFountainFillBlendType.
Mode
Specifies the blend mode, and returns cdrBlendMode.
Spacing
Double
Specifies the blend spacing.
Angle
Double
Specifies the blend angle.
Loop
Boolean
Specifies whether the blend loops.
Path
Specifies the blend path.
RotateShapes
Boolean
Specifies whether the blend rotates its shape to follow a path.
SpacingAccel
Long
Specifies the rate of object acceleration.
ColorAccel
Long
Specifies the rate of color acceleration. Higher numbers allow the colors to move more quickly through the spectrum as they approach the end object.
AccelSize
Boolean
Specifies whether the size of the blend accelerates along the path.
Remarks:
The CreateBlend method creates a blend between two shapes, returning an Effect object that represents the blend-effect properties.
Examples:
The following VBA example creates a blend on path between two ellipses.
Sub Test()
Dim sPath As Shape, s1 As Shape, s2 As Shape
Dim eff As Effect
Set sPath = ActiveLayer.CreateCurveSegment(1, 6.5, 5, 8.5, 2, 72, 1.8, 180)
Set s1 = ActiveLayer.CreateEllipse(0.953386, 6.731929, 1.838858, 6.027165)
s1.Fill.UniformColor.CMYKAssign 0, 100, 100, 0
Set s2 = ActiveLayer.CreateEllipse(4.838622, 9.045, 5.597598, 8.21374)
s2.Fill.UniformColor.CMYKAssign 0, 0, 100, 0
Set eff = s2.CreateBlend(s1, 10)
eff.Blend.Path = sPath 
End Sub