![]() |
![]() |
FountainFill.Steps
Property Steps As Long
Member of FountainFill
The Steps property returns or sets the number of steps in a fountain fill. The value can range from 2 to 999. If the value is equal to zero, the default number of steps of the document is used.
The following code example searches through all shapes on the current page for a fountain fill with a specified number of fountain steps (that is, where the value of the Steps property is not 0). If a shape was selected before this macro was played, it searches for the next shape with a fixed number of steps.
Sub FindFixedSteps() Dim s As Shape, id As Long Dim bLoop As Boolean Set s = ActiveShape If s Is Nothing Then ' Nothing selected. Get the first shape on the page. Set s = ActivePage.Shapes(1) If TestShape(s) Then s.CreateSelection Exit Sub ' Shape Found End If End If id = s.StaticID ' Remember the ID of the selected shape. Do Set s = s.Next(cdrLevelPage, True, True) ' Get the next shape. If TestShape(s) Then s.CreateSelection Exit Sub ' Shape Found End If Loop While id <> s.StaticID ' Loop until we find the selected shape again. MsgBox "Shape not found", vbCritical End Sub ' The following function is used to see if the current shape is the one ' we are looking for. Private Function TestShape(s As Shape) As Boolean Dim b As Boolean b = False If s.Fill.Type = cdrFountainFill Then If s.Fill.Fountain.Steps <> 0 Then b = True End If TestShape = b End Function
![]() |
![]() |
![]() |
Copyright 2007 Corel Corporation. All rights reserved.