Thread
:
Macro to delete various pictures and hyper-link picture icons
View Single Post
#
11
Posted to microsoft.public.excel.worksheet.functions
Steve
external usenet poster
Posts: 1,814
Macro to delete various pictures and hyper-link picture icons
Don,
Thanks so much for all your help and patience. I really apprecaite it.
Always learning.
I was able to re-name it the button now. Maybe my older home Excel version
did not allow it. And by naming that form button rectangle, it worked great.
One thing I'm still a bit confused about.
is the macro not deleting the "rectangle' because the macro is indicating:...
if it is not named rectangle ( the <) or not deleting it because it's 9
characters.
Or are both needed ?
or .??????
Thanks again,
Steve
"Don Guillett" wrote:
Of course you can rename. I assume you have a button from the FORMS toolbar.
Select itin the NAME box to the left of the formula box type in whatever
you desire.
BTW Button is NOT 9 characters, is it?
--
Don Guillett
SalesAid Software
"Steve" wrote in message
...
Yes, it definitely worked, and much appreciated. Also the unprint.
I guess you can't re-name the buttons to rectangle, because I wanted to
try
to use it that way. I even tried to reword your macro, replacing rectangle
to
button, but I couldn't it to work.
Thanks agian for all your help.
Steve
"Don Guillett" wrote:
If you click on the rectangle and look in the NAME box to the left of the
formula box you will see the name of the shape. You may go there and name
it
whatever you like such as joe1, bill2, etc. IF named Rectangle 1 then my
macro should have worked.
Right click on the shape until you see a many optioned menuselect format
auto shape propertiesunclick print.
--
Don Guillett
SalesAid Software
"Steve" wrote in message
...
I didn't realize you could assign a macro to shape from the drawing
toolbar.
And it worked, however, the shape also prints. My buttons didn't, which
is
what I'd prefer.
Also, I don't understand what you're referring to regarding 'leaving
the
names alone'.
I was also hoping that seeing the 'delete non-rectangle', my rectangle
button would not have been deleted, but it still was deleted.
Can the printing of the drawing toolbar shape be supressed ?
Or is there a way with 'names' to prevent a button from being deleted ?
Thanks again,
Steve
"Don Guillett" wrote:
Since I almost always use shapes from the drawing toolbar and leave
the
names alone. Or, you could re-name those to keep and exclude those.
Sub deletenonrectangleshapes()
For Each s In ActiveSheet.Shapes
If Left(s.Name, 9) < "Rectangle" Then s.Delete
Next s
End Sub
--
Don Guillett
SalesAid Software
"Steve" wrote in message
...
Well, now that you mention it......
Yes, I use forms\buttons that I assign my Macros to, and it also
deleted
those buttons. Is there something else I could use on the sheet
(like a
macro
button) that will run the macro but not be deleted ?
Thanks,
Steve
"Don Guillett" wrote:
Glad to help. Hope it didn't wipe out any shapes needed.
--
Don Guillett
SalesAid Software
"Steve" wrote in message
...
Perfect !! And so simple.
Thanks.
"Don Guillett" wrote:
try
sub deleteshapes()
for each s in activesheet.shapes
s.delete
next s
end sub
--
Don Guillett
SalesAid Software
"Steve" wrote in message
...
I copy whole data sheets onto Excel. They have various pictures
and
hyper-link picture icons. Is there a macro I could run to
delete
all
of
this
extraneous stuff ?
Thanks,
Steve
Reply With Quote
Steve
View Public Profile
Find all posts by Steve