A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Powerpoint, Publisher and Visio » Powerpoint
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Macro for Ungrouping Presentation



 
 
Thread Tools Display Modes
  #1  
Old June 4th, 2010, 09:10 PM posted to microsoft.public.powerpoint
Phosphide
external usenet poster
 
Posts: 3
Default Macro for Ungrouping Presentation

Hello,
I am trying to write a macro that would take all the images in a
presentation and ungroup them. However, I cannot get it to work correctly.

Here is the code:

Sub UngroupTheOLEs()

Dim oSlides As Slides
Dim oSld As Slide
Dim oShapes As Shapes
Dim oShp As Shape
Dim oShapeRange As ShapeRange

Set oSlides = ActiveWindow.Presentation.Slides
For Each oSld In oSlides
Set oShapes = oSld.Shapes
For Each oShp In oShapes
If oShp.Type = msoEmbeddedOLEObject Or oShp.Type =
msoLinkedOLEObject Then
Set oShapeRange = oShp.Ungroup
oShapeRange.Group
End If
Next oShp
Next oSld

End Sub

I ran through the Step-In process and the compiler appears to be skipping
the actual ungrouping code. Anyone have a suggestion?
 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 11:07 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.