shortcut key to macro variables

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

My macro variables are often long and hard to keep retyping.

When I'm programming a macro, is there a shortcut or pull down menu to
select variables already is use?

This would be faster and would also prevent mistyping.
 
You can go to View>Locals Window while you are stepping into a macro and it
will show all the variables in that particular macro. It will not give you a
menu of variables to pick from. There is nothing that I know of that will do
what you described. However, some code writers use the Dim declarations at
the top of the macro to track their variables by making the declaration as
soon as they assign the variable.

Another technique, is to keep the procedures short so that the number of
variables per procedure are minimized. Then, if you happen to use the same
variable in a different procedure, it will not cause an error. This concept
uses a master procedure to call a series of small procedures in their logical
order. It is easy to track your variables and it periodically frees up
memory so that the code runs better.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top