API Documentation > CorelDRAW > 2025-v26 > Shape > IVGShape
Shape.CreateDropShadow method
Applies a dropshadow effect to a shape
Syntax:
Function CreateDropShadow(Optional ByVal Type As cdrDropShadowType = cdrDropShadowFlat, Optional ByVal Opacity As Long = 50, Optional ByVal Feather As Long = 15, Optional ByVal OffsetX As Double = 0, Optional ByVal OffsetY As Double = 0, Optional ByVal Color As Color = Nothing, Optional ByVal FeatherType As cdrFeatherType = cdrFeatherGaussianBlur, Optional ByVal FeatherEdge As cdrEdgeType = cdrEdgeLinear, Optional ByVal PerspectiveAngle As Double = -45, Optional ByVal PerspectiveStretch As Double = 1, Optional ByVal Fade As Long = 1, Optional ByVal MergeMode As cdrMergeMode = cdrMergeNormal) As Effect
Parameters:
Name Type Description
Type
Specifies the type of drop shadow, and returns cdrDropShadowType.
Opacity
Long
Specifies the opacity value of the drop shadow. Values range from 0 to 100. Low values create a less opaque drop shadow, while high values create a more opaque drop shadow.
Feather
Long
Specifies the feather length for the drop shadow. Values range from 0 to 100. Low values create a more subtle feathering effect, while high values create a more pronounced effect.
OffsetX
Double
Specifies the horizontal offset of the drop shadow.
OffsetY
Double
Specifies the vertical offset of the drop shadow.
Color
Specifies the color of the drop shadow.
FeatherType
Specifies the feather type for the drop shadow, and returns cdrFeatherType. Values range from 0 to 100. Low values create a more subtle feathering effect, while high values create a more pronounced effect.
FeatherEdge
Specifies the feather edge for the drop shadow, and returns cdrEdgeType. Values range from 0 to 100.
PerspectiveAngle
Double
Specifies the feather perspective angle in the drop shadow.
PerspectiveStretch
Double
Specifies the feather perspective stretch value in the drop shadow.
Fade
Long
Specifies the fade value of the drop shadow. The fade level of a drop shadow that has a Flat perspective cannot be changed.
MergeMode
Specifies the merge mode for the drop shadow.
Remarks:
The CreateDropShadow method applies a drop shadow to a shape, returning an Effect object that represents the drop-shadow properties.
Examples:
The following VBA example creates a cut-out effect.
Sub Test()
Const Border As Double = 0.5
Dim s As Shape, sRect As Shape, sShadow As Shape
Dim eff As Effect, sr As New ShapeRange
Dim x As Double, y As Double, sx As Double, sy As Double
Set s = ActiveLayer.CreateArtisticText(4, 5, "Cut")
With s.Text.FontProperties
  .Name = "Arial"
  .Size = 200
  .Style = cdrBoldFontStyle
End With
s.Text.AlignProperties.Alignment = cdrCenterAlignment
s.GetBoundingBox x, y, sx, sy
Set sRect = ActiveLayer.CreateRectangle2(x - Border, y - Border, sx + 2 * Border, sy + 2 * Border)
s.Selected = True
Set sRect = ActiveSelection.Combine
sRect.Fill.UniformColor.CMYKAssign 30, 0, 0, 0
Set eff = sRect.CreateDropShadow(cdrDropShadowFlat, 80, 10, 0.2, -0.2, CreateCMYKColor(0, 0, 0, 100))
eff.Separate
Set sShadow = sRect.Next
Set s = ActiveLayer.CreateRectangle2(x, y, sx, sy)
s.Fill.ApplyNoFill
s.Outline.Type = cdrNoOutline
sShadow.AddToPowerClip s
s.OrderBackOf sRect
sr.Add s
sr.Add sRect
sr.Group.CreateSelection 
End Sub