API Documentation > CorelDRAW > 2025-v26 > Effect > IVGEffect
Effect.ControlPath property
Gets the control path for the object
Syntax:
Property Get ControlPath() As EffectControlPath
Remarks:
The ControlPath property returns an EffectControlPath object.
Examples:
The following VBA example checks whether there are any blends or text attached to the currently selected path. All blends are changed so that the object's transition in color from yellow to blue, and all text objects become filled with red.
Sub Test()
Dim e1 As Effect, e2 As Effect
For Each e1 In ActiveShape.Effects
  If e1.Type = cdrControlPath Then

 MsgBox "There are " & e1.ControlPath.Effects.Count & " effect objects on this path"

 For Each e2 In e1.ControlPath.Effects


Select Case e2.Type


  Case cdrTextOnPath



 e2.TextOnPath.Text.Fill.UniformColor.RGBAssign 255, 0, 0


  Case cdrBlend



 e2.Blend.StartShape.Fill.UniformColor.RGBAssign 255, 255, 0



 e2.Blend.EndShape.Fill.UniformColor.RGBAssign 0, 0, 255


End Select

 Next e2

 Exit For
  End If
Next e1 
End Sub