In VBA can I assign a shortcut key to a macro?

  • Thread starter Patrick Steranka
  • Start date
P

Patrick Steranka

I'd like to write a MyConfig() subroutine which simply assigns some shortcut
keys to some macros that I have. I do this manually now, and am wondering
if there is a way to automate this.

For example, I want to assign Ctrl+T to expand outline (OutlineShowSubTasks).

Thanks,
Patrick
 
R

Rod Gill

Hi,

Firstly, Alt+Shift+(Num Pad -) hides sub tasks and Alt+Shift+(Num Pad +)
shows sub tasks.

Search help for shortcut keys for more options.

To add shortcut keys it's exactly the same as in Excel:
Tools, Macro, Macros
Select your Macro and click the Options button
Enter your key. Unfortunately Project on lets you use about 8 currently
unused keys so you need to experiment to see which ones are available to use
for your version of Project. (I've requested the same options as in Excel
(shift keys etc) many times but no luck yet!)
 

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

Top