Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 20
Default Shapes In ActiveSheet

Hello!
Can someone help me how I get all Shapes (which I am using as buttons for
macros) deleted in activesheet.
The problem is that I don't know the name of those Shapes. (There is also
Shapes in other sheets, which should not be deleted)

I thank you for your help!

BR,
Tommi


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 7,247
Default Shapes In ActiveSheet

Tommi,

Try something like

Dim SH As Shape
For Each SH In ActiveSheet.Shapes
SH.Delete
Next SH



--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com


"Tommi" wrote in message
...
Hello!
Can someone help me how I get all Shapes (which I am using as

buttons for
macros) deleted in activesheet.
The problem is that I don't know the name of those Shapes.

(There is also
Shapes in other sheets, which should not be deleted)

I thank you for your help!

BR,
Tommi




  #3   Report Post  
Posted to microsoft.public.excel.programming
No Name
 
Posts: n/a
Default Shapes In ActiveSheet

Tommi,

Try this:

For each shp in ActiveSheet.Shapes
shp.Select
Selection.Delete
Next

Nikos
-----Original Message-----
Hello!
Can someone help me how I get all Shapes (which I am

using as buttons for
macros) deleted in activesheet.
The problem is that I don't know the name of those

Shapes. (There is also
Shapes in other sheets, which should not be deleted)

I thank you for your help!

BR,
Tommi


.

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,080
Default Shapes In ActiveSheet

Hi Chip:

Interestingly,

ActiveSheet.Shapes.Delete

does not work, while:

ActiveSheet.DrawingObjects.Delete

does.

Why the difference? Aren't they equivalent? Help seems to refer to
DrawingObjects and Shapes interchangeably.

Regards,

Vasant.


"Chip Pearson" wrote in message
...
Tommi,

Try something like

Dim SH As Shape
For Each SH In ActiveSheet.Shapes
SH.Delete
Next SH



--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com


"Tommi" wrote in message
...
Hello!
Can someone help me how I get all Shapes (which I am using as

buttons for
macros) deleted in activesheet.
The problem is that I don't know the name of those Shapes.

(There is also
Shapes in other sheets, which should not be deleted)

I thank you for your help!

BR,
Tommi






  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 691
Default Shapes In ActiveSheet

Hi Tommi,
Shapes
http://www.mvps.org/dmcritchie/excel/shapes.htm
in case your question was not answered. I think you wanted to
identify the name of a shape.

You shoujld put your name (first & last) even when posting
with anonymous email address at least it is a bit more friendly
most of regulars also do use their real email address and do
deal with the spam to email with filters.

Newsgroup postings are archived, and if I wanted to see if anyone
replied to my post I could put or
I could put "David McRitchie" in as author and limit to a date range
to find if anyone replied to my question.
http://www.mvps.org/dmcritchie/excel/xlnews.htm
---
HTH,
David McRitchie, Microsoft MVP - Excel [site changed Nov. 2001]
My Excel Pages: http://www.mvps.org/dmcritchie/excel/excel.htm
Search Page: http://www.mvps.org/dmcritchie/excel/search.htm

wrote in message ...
Tommi,

Try this:

For each shp in ActiveSheet.Shapes
shp.Select
Selection.Delete
Next

Nikos
-----Original Message-----
Hello!
Can someone help me how I get all Shapes (which I am

using as buttons for
macros) deleted in activesheet.
The problem is that I don't know the name of those

Shapes. (There is also
Shapes in other sheets, which should not be deleted)

I thank you for your help!

BR,
Tommi


.





  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default Shapes In ActiveSheet

Absolutely agree, and it seems to be on the increase. It is nice to know who
you are talking to.

Bob

"David McRitchie" wrote in message
...
Hi Tommi,
Shapes
http://www.mvps.org/dmcritchie/excel/shapes.htm
in case your question was not answered. I think you wanted to
identify the name of a shape.

You shoujld put your name (first & last) even when posting
with anonymous email address at least it is a bit more friendly
most of regulars also do use their real email address and do
deal with the spam to email with filters.

Newsgroup postings are archived, and if I wanted to see if anyone
replied to my post I could put or
I could put "David McRitchie" in as author and limit to a date range
to find if anyone replied to my question.
http://www.mvps.org/dmcritchie/excel/xlnews.htm
---
HTH,
David McRitchie, Microsoft MVP - Excel [site changed Nov. 2001]
My Excel Pages: http://www.mvps.org/dmcritchie/excel/excel.htm
Search Page: http://www.mvps.org/dmcritchie/excel/search.htm

wrote in message

...
Tommi,

Try this:

For each shp in ActiveSheet.Shapes
shp.Select
Selection.Delete
Next

Nikos
-----Original Message-----
Hello!
Can someone help me how I get all Shapes (which I am

using as buttons for
macros) deleted in activesheet.
The problem is that I don't know the name of those

Shapes. (There is also
Shapes in other sheets, which should not be deleted)

I thank you for your help!

BR,
Tommi


.





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
excel document with shapes on it but the shapes do not print [email protected] Excel Worksheet Functions 2 October 22nd 09 06:17 PM
Naming Auto Shapes and Creating new Shapes AL2000 Excel Discussion (Misc queries) 3 September 10th 07 04:12 AM
When drawing shapes in excel the shapes keep disappearing Tape Excel Discussion (Misc queries) 1 October 6th 06 04:23 PM
How can i get more 3D shapes for Auto shapes in excel? Ajey Excel Discussion (Misc queries) 0 March 3rd 05 09:53 AM
How can i get more 3D shapes for Auto shapes in excel? Ajey Excel Discussion (Misc queries) 0 March 3rd 05 09:53 AM


All times are GMT +1. The time now is 07:42 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"