Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 32
Default Automate delete macros

I have some xl files that have many macros in them. For
example 20 xl files with 10 macros in each file. I have
to give a final version of the files to management. I do
not want management to see my macros...the macros are my
edge.

I have the following macro in it's own xl file that I use
to delete the macros in the other files before I save the
xl files in management's directory.

Sub zzzDeleteMacros()
Dim vStop As Double
vStop = 0
Do Until vStop = 50
Application.SendKeys Keys:="%tmm", Wait:=False
Application.SendKeys Keys:="%D", Wait:=False
Application.SendKeys Keys:="Y", Wait:=False
vStop = vStop + 1
Loop
End Sub

This works fine except that it also will delete the macro
zzzDeleteMacros(). Then I just do not save the delete
macro file. It's name is zzzDeleteMacros() because I want
it to be the last macro in the list of approx 200 or more
macros.

Is there a way to ask the name of the macro selected in
the Macro Run Dialog box so that when it gets to
zzzDeleteMacros() I can show a message "Process Complete"
and then Exit Sub.

Thank you for your help.

Steven



  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,120
Default Automate delete macros

Two points.

If you develop code in work time, it is the company 's property not yours?

If the final files do not need the macros, why put them there? Why not just
store them in an other file so that you can use when developing?

--
HTH

-------

Bob Phillips
"Steven" wrote in message
...
I have some xl files that have many macros in them. For
example 20 xl files with 10 macros in each file. I have
to give a final version of the files to management. I do
not want management to see my macros...the macros are my
edge.

I have the following macro in it's own xl file that I use
to delete the macros in the other files before I save the
xl files in management's directory.

Sub zzzDeleteMacros()
Dim vStop As Double
vStop = 0
Do Until vStop = 50
Application.SendKeys Keys:="%tmm", Wait:=False
Application.SendKeys Keys:="%D", Wait:=False
Application.SendKeys Keys:="Y", Wait:=False
vStop = vStop + 1
Loop
End Sub

This works fine except that it also will delete the macro
zzzDeleteMacros(). Then I just do not save the delete
macro file. It's name is zzzDeleteMacros() because I want
it to be the last macro in the list of approx 200 or more
macros.

Is there a way to ask the name of the macro selected in
the Macro Run Dialog box so that when it gets to
zzzDeleteMacros() I can show a message "Process Complete"
and then Exit Sub.

Thank you for your help.

Steven





  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 32
Default Automate delete macros

Heres two more points.
First of all I did not say I did this on company's
time...DID I. Second I barely have enought time to do my
work so if I create things ...ON MY OWN TIME...then I
guess it is my property....ISNT IT!!!!!

-----Original Message-----
Two points.

If you develop code in work time, it is the company 's

property not yours?

If the final files do not need the macros, why put them

there? Why not just
store them in an other file so that you can use when

developing?

--
HTH

-------

Bob Phillips
"Steven" wrote in

message
...
I have some xl files that have many macros in them. For
example 20 xl files with 10 macros in each file. I have
to give a final version of the files to management. I

do
not want management to see my macros...the macros are my
edge.

I have the following macro in it's own xl file that I

use
to delete the macros in the other files before I save

the
xl files in management's directory.

Sub zzzDeleteMacros()
Dim vStop As Double
vStop = 0
Do Until vStop = 50
Application.SendKeys Keys:="%tmm", Wait:=False
Application.SendKeys Keys:="%D", Wait:=False
Application.SendKeys Keys:="Y", Wait:=False
vStop = vStop + 1
Loop
End Sub

This works fine except that it also will delete the

macro
zzzDeleteMacros(). Then I just do not save the delete
macro file. It's name is zzzDeleteMacros() because I

want
it to be the last macro in the list of approx 200 or

more
macros.

Is there a way to ask the name of the macro selected in
the Macro Run Dialog box so that when it gets to
zzzDeleteMacros() I can show a message "Process

Complete"
and then Exit Sub.

Thank you for your help.

Steven





.

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,120
Default Automate delete macros

Touch a raw nerve?

--
HTH

-------

Bob Phillips
"Steven" wrote in message
...
Heres two more points.
First of all I did not say I did this on company's
time...DID I. Second I barely have enought time to do my
work so if I create things ...ON MY OWN TIME...then I
guess it is my property....ISNT IT!!!!!

-----Original Message-----
Two points.

If you develop code in work time, it is the company 's

property not yours?

If the final files do not need the macros, why put them

there? Why not just
store them in an other file so that you can use when

developing?

--
HTH

-------

Bob Phillips
"Steven" wrote in

message
...
I have some xl files that have many macros in them. For
example 20 xl files with 10 macros in each file. I have
to give a final version of the files to management. I

do
not want management to see my macros...the macros are my
edge.

I have the following macro in it's own xl file that I

use
to delete the macros in the other files before I save

the
xl files in management's directory.

Sub zzzDeleteMacros()
Dim vStop As Double
vStop = 0
Do Until vStop = 50
Application.SendKeys Keys:="%tmm", Wait:=False
Application.SendKeys Keys:="%D", Wait:=False
Application.SendKeys Keys:="Y", Wait:=False
vStop = vStop + 1
Loop
End Sub

This works fine except that it also will delete the

macro
zzzDeleteMacros(). Then I just do not save the delete
macro file. It's name is zzzDeleteMacros() because I

want
it to be the last macro in the list of approx 200 or

more
macros.

Is there a way to ask the name of the macro selected in
the Macro Run Dialog box so that when it gets to
zzzDeleteMacros() I can show a message "Process

Complete"
and then Exit Sub.

Thank you for your help.

Steven





.



  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 32
Default Automate delete macros

I don't mind answering questions on this website or
sharing code here (I really dont know how good I am
because I see there are a lot of hard core coders here).
But I will never give my code to the people above me who
are nothing but oppressors and want want and want more and
want to be spoon-fed and for your efforts they give you
squat.

I am glad you responded like that because that was funny.


  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,120
Default Automate delete macros

As someone who gives code away, and someone who uses lots of very
high-quality free code, I feel very un-protective of my code. Also, we
either believe in market economies or we don't, I don't find much value in
pushing against them in such a small way.

Anyway, I am glad you found my response amusing. I also found your initial
response funny, so we end better than we started,

BTW, my second point still seems viable to me.

--
HTH

-------

Bob Phillips
"Steven" wrote in message
...
I don't mind answering questions on this website or
sharing code here (I really dont know how good I am
because I see there are a lot of hard core coders here).
But I will never give my code to the people above me who
are nothing but oppressors and want want and want more and
want to be spoon-fed and for your efforts they give you
squat.

I am glad you responded like that because that was funny.



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
automate delete rows without data Amir Excel Worksheet Functions 3 August 19th 09 03:38 PM
delete macros AhmetDY Excel Discussion (Misc queries) 2 October 18th 07 10:07 AM
Automate a macros when data in a cell changes (e.g.when using quer jwwjd Excel Discussion (Misc queries) 5 June 24th 05 03:06 PM
How to delete macros Jaime Stuardo Excel Discussion (Misc queries) 2 February 14th 05 02:29 PM
Automate Macros Tom Excel Programming 4 June 14th 04 08:09 PM


All times are GMT +1. The time now is 10:04 PM.

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"