![]() |
#1
|
|||
|
|||
![]()
Hi again!
Having a bit of a problem here with apparently non-existing shapes being added to a ShapeRange. The general use is more complex, but I have picked out a smaller portion for testing purposes. To test it out you would create a shape with a, say, shadow effect and some other regular shapes, like rectangles. Then run this: Code:
Sub PicksWhatItShouldnt() Dim SR As ShapeRange Dim S As Shape Set SR = ActivePage.Shapes.FindShapes() SR.RemoveRange SR.FindAnyOfType(cdrNoShape, cdrBitmapShape, cdrTextShape, cdrBlendGroupShape, cdrExtrudeGroupShape, _ cdrOLEObjectShape, cdrContourGroupShape, cdrLinearDimensionShape, cdrBevelGroupShape, cdrDropShadowGroupShape, _ cdr3DObjectShape, cdrArtisticMediaGroupShape, cdrConnectorShape, cdrMeshFillShape, cdrCustomShape, _ cdrCustomEffectGroupShape, cdrSymbolShape, cdrHTMLFormObjectShape, cdrHTMLActiveObjectShape, cdrPerfectShape, cdrEPSShape) For Each S In SR If S.Outline.Type <> cdrNoOutline And S.Outline.Color.Name <> "None" Then S.Outline.Color.ConvertToLab End If Next S End Sub ![]() Any ideas? The main goal here is to do something with the fill and outline of each and every shape that supports such actions. |
#2
|
|||
|
|||
![]()
Alright, I managed to come up with a solution to this, that, while not too elegant still seems to function well. Use the power of .findshapes in small, controlled bursts, like this:
Code:
Dim SR As ShapeRange Set SR = ActiveSelectionRange.Shapes.FindShapes(Type:="1", Recursive:=True) SR.AddRange ActiveSelectionRange.Shapes.FindShapes(Type:="2", Recursive:=True) SR.AddRange ActiveSelectionRange.Shapes.FindShapes(Type:="3", Recursive:=True) SR.AddRange ActiveSelectionRange.Shapes.FindShapes(Type:="4", Recursive:=True) SR.AddRange ActiveSelectionRange.Shapes.FindShapes(Type:="6", Recursive:=True) ![]() |
#3
|
||||
|
||||
![]()
Hi.
I would try a cql query. I have fed some extremely large strings to CQL and it eats them well. ~John |
![]() |
Tags |
findshapes |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
FindShapes & PowerClips | ddonnahoe | Macros/Add-ons | 1 | 01-08-2012 17:45 |
about effects group... | 3dvr | CorelDRAW/Corel DESIGNER VBA | 2 | 01-07-2009 15:06 |
FindShapes Selection irregularity | Shaddy | CorelDRAW/Corel DESIGNER VBA | 2 | 18-07-2006 21:41 |
[VBA] FindShapes reduced behaviour in X3 ;-( | wOxxOm | CorelDRAW/Corel DESIGNER VBA | 0 | 05-06-2006 11:50 |
[s.Effects.LensEffect] is Error | hotswin | CorelDRAW/Corel DESIGNER VBA | 10 | 29-08-2005 03:00 |