Hello.
I'm trying to create a macro that reverts all the selected shapes from PowerClip to normal shapes but without success.
My question is: Where is the PowerClip - Frame - No Frame in the VBA. I can't find it.
And no, if you have more than one PowerClip selected you can't access this menu item.
Because I usually do this for many shapes at once it would be greate to have.
My current code is:
Sub RevertPowerClipToShape() ActiveDocument.ReferencePoint = cdrCenter Dim OrigSelection As ShapeRange Set OrigSelection = ActiveSelectionRange Dim s As Shape If ActiveSelectionRange.Count = 0 Then MsgBox "No shapes selected" Exit Sub Else For Each s In OrigSelection s.PowerClip.Shapes.All.Delete Next s End IfEnd Sub
This removes the objects inside the powerclip but I still have the Frame on the shape.
Any help would be appreciated.
Best regards.
How about if we perform a mouse click on that item??Is this even possible?
I do not understand what you mean by 'perform a mouse click'? To do that programmatically according to some parameters?
But beside that the next example of code does not work for you?
You should select the POWERCLIP SHAPE!
Dim S as Shape
Set S = Active Shape
S.PowerClip.ExtractShapes
S.PowerClip.Parent.Delete