Previous Document Next Document
Application.ActiveSelection

Property ActiveSelection As Shape

Member of Application

The ActiveSelection property returns the active selection in the active document.

The ActiveSelection property returns a read-only value.

The following code example colors the selected shapes green, if the shape selected is an ellipse.

Sub SelectionActive() 
 Dim s As Shape 
 For Each s In ActiveSelection.Shapes 
  If s.Type = cdrEllipseShape Then 
   s.Fill.UniformColor.CMYKAssign 100, 0, 100, 0 
  End If 
 Next s 
End Sub 

Previous Document Next Document Back to Top

Copyright 2007 Corel Corporation. All rights reserved.