Share via


DashStyle Property

MsoLineDashStyle

MsoLineDashStyle can be one of these MsoLineDashStyle constants.
msoLineDashDot
msoLineDashStyleMixed
msoLineLongDashDot
msoLineSolid
msoLineDash
msoLineDashDotDot
msoLineLongDash
msoLineRoundDot
msoLineSquareDot

expression.DashStyle

expression Required. An expression that returns one of the objects in the Applies To list.

Example

This example adds a blue dashed line to the active document.

Dim docActive As Document

Set docActive = ActiveDocument

With docActive.Shapes.AddLine(10, 10, 250, 250).Line
    .DashStyle = msoLineDashDotDot
    .ForeColor.RGB = RGB(50, 0, 128)
End With

Applies to | LineFormat Object