Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 193
Default Selecting Autoshapes

I have a bit of a dilemma, I hope someone in here can help me with.

I have created a spreadsheet that selects and pastes a specific Autoshape to
a specific location based on a formula. Once the Autoshapes are inserted I
want to be able to select them all to group them and move them as needed.

The problem is The autoshapes can be named anything based on the Macro and
formula. How can I select all the shapes in a given area no mater what they
are called?

This is what I have now...

ActiveSheet.Shapes.Range(Array("GroupA", "Three", "Apple", "Three_A")).Select
Selection.ShapeRange.Group.Select

The problem come in when selecting this because "Three, Apple and Three_A".
These names can be anything... "Two, Seven, Orange, Black_A and so on.

The only constant is "GroupA". and GroupA can be in Range(D14:G16), From
there, there will be a GroupB with the same problem and circumstances listed
above. GroupB is located in Range(I14:L16).

Perplexing, I know....
Can anyone help?
--
Pete
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 695
Default Selecting Autoshapes


ActiveSheet.Shapes.SelectAll


"Pete" skrev:

I have a bit of a dilemma, I hope someone in here can help me with.

I have created a spreadsheet that selects and pastes a specific Autoshape to
a specific location based on a formula. Once the Autoshapes are inserted I
want to be able to select them all to group them and move them as needed.

The problem is The autoshapes can be named anything based on the Macro and
formula. How can I select all the shapes in a given area no mater what they
are called?

This is what I have now...

ActiveSheet.Shapes.Range(Array("GroupA", "Three", "Apple", "Three_A")).Select
Selection.ShapeRange.Group.Select

The problem come in when selecting this because "Three, Apple and Three_A".
These names can be anything... "Two, Seven, Orange, Black_A and so on.

The only constant is "GroupA". and GroupA can be in Range(D14:G16), From
there, there will be a GroupB with the same problem and circumstances listed
above. GroupB is located in Range(I14:L16).

Perplexing, I know....
Can anyone help?
--
Pete

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 695
Default Selecting Autoshapes

Or if u only ned some of the shapes
this return all shape names

Sub ShapeNames()

For Each ch In ActiveSheet.Shapes
x = x & vbLf & ch.Name
Next

MsgBox ("Shape Names") & vbLf & x

End Sub



"Pete" skrev:

I have a bit of a dilemma, I hope someone in here can help me with.

I have created a spreadsheet that selects and pastes a specific Autoshape to
a specific location based on a formula. Once the Autoshapes are inserted I
want to be able to select them all to group them and move them as needed.

The problem is The autoshapes can be named anything based on the Macro and
formula. How can I select all the shapes in a given area no mater what they
are called?

This is what I have now...

ActiveSheet.Shapes.Range(Array("GroupA", "Three", "Apple", "Three_A")).Select
Selection.ShapeRange.Group.Select

The problem come in when selecting this because "Three, Apple and Three_A".
These names can be anything... "Two, Seven, Orange, Black_A and so on.

The only constant is "GroupA". and GroupA can be in Range(D14:G16), From
there, there will be a GroupB with the same problem and circumstances listed
above. GroupB is located in Range(I14:L16).

Perplexing, I know....
Can anyone help?
--
Pete

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 193
Default Selecting Autoshapes

Thank you for this, but I do not need to select every Autoshape in the active
worksheet, just a few depending on the application. Again these few autoshape
can be named anything...
--
Pete


"excelent" wrote:


ActiveSheet.Shapes.SelectAll


"Pete" skrev:

I have a bit of a dilemma, I hope someone in here can help me with.

I have created a spreadsheet that selects and pastes a specific Autoshape to
a specific location based on a formula. Once the Autoshapes are inserted I
want to be able to select them all to group them and move them as needed.

The problem is The autoshapes can be named anything based on the Macro and
formula. How can I select all the shapes in a given area no mater what they
are called?

This is what I have now...

ActiveSheet.Shapes.Range(Array("GroupA", "Three", "Apple", "Three_A")).Select
Selection.ShapeRange.Group.Select

The problem come in when selecting this because "Three, Apple and Three_A".
These names can be anything... "Two, Seven, Orange, Black_A and so on.

The only constant is "GroupA". and GroupA can be in Range(D14:G16), From
there, there will be a GroupB with the same problem and circumstances listed
above. GroupB is located in Range(I14:L16).

Perplexing, I know....
Can anyone help?
--
Pete

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Selecting Autoshapes in Excel 2003 Varne Excel Discussion (Misc queries) 2 May 24th 08 01:53 PM
autoshapes babirt Excel Worksheet Functions 0 March 22nd 07 01:58 PM
Autoshapes lboushey Excel Discussion (Misc queries) 3 March 7th 06 10:12 PM
autoshapes AmyTaylor[_26_] Excel Programming 7 September 3rd 05 09:02 PM
Selecting All AutoShapes on a Worksheet Alan Excel Programming 1 May 28th 04 12:51 AM


All times are GMT +1. The time now is 06:06 AM.

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

About Us

"It's about Microsoft Excel"