View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Darrell Lankford Darrell Lankford is offline
external usenet poster
 
Posts: 28
Default Select Embedded Documents

Does anyone know a code that will select only the embedded documents
on a sheet? I’m trying to setup a code that will copy and paste the
embedded documents to another sheet, but I can’t figure out how to
keep the code from selecting all the other objects on the sheet. I
have Form Buttons, Option Buttons, & embedded PDF, Excel, or Word
documents. I only want the code to select the embedded documents.

I have tried…..
ActiveSheet.Shapes.SelectAll

I have tried…..
ActiveSheet.OLEObjects.Select

I have tried…..
Dim shp As Shape
For Each shp In ActiveSheet.Shapes
If shp.Type = msoEmbeddedOLEObject Then
ActiveSheet.Shapes.SelectAll
End If
Next

But, they all select the buttons with the embedded documents. I only
want to select the embedded documents. Any help would be greatly
appreciated.