Jump to content
Macro Express Forums

How can I open a program+run a hotkey within it?


escobar

Recommended Posts

I would like to create a certain shortcut.

It must open a program, then execute a hotkey multiple times.

 

I need it to open this program:

C:\Program Files\Microsoft Office\Office12\ONENOTE.EXE

 

I need it to execute this hotkey 5 times:

CTRL+M

 

Does anyone know how this can be done?

 

 

...........

 

 

Extra Note:

Some of you maybe wondering why I need the hotkey.

OneNote does not let you open multiple windows, unless you use the hotkey.

Using the hotkey 5 times allows me to open 5 windows.

Link to comment
Share on other sites

It looks like all you need to do is set up a loop to press the Cntrl+M 5 times. Try something like this:

 

Activate or Launch: "One" OR "ONENOTE.EXE"
Repeat Start (Repeat 5 times)
 Control Key Down
   Text Type: m
 Control Key Up
Repeat End

 

You may need to enter a small delay before the end of the loop, depending on your machine, but this should do the trick.

Link to comment
Share on other sites

It looks like all you need to do is set up a loop to press the Cntrl+M 5 times. Try something like this:

 

Activate or Launch: "One" OR "ONENOTE.EXE"
Repeat Start (Repeat 5 times)
 Control Key Down
   Text Type: m
 Control Key Up
Repeat End

 

You may need to enter a small delay before the end of the loop, depending on your machine, but this should do the trick.

 

Thank you so much for your help!

 

I just found a working "Direct Script Editor" combination:

<LAUNCHDEL2:0:01C:\Program Files\Microsoft Office\Office12\ONENOTE.EXE><DELAY:3><TEXTTYPE:<CONTROL>m><DELAY:1><TEXTTYPE:<CONTROL>m><DELAY:1><TEXTTYPE:<CONTROL>m><DELAY:1><TEXTTYPE:<CONTROL>m><DELAY:1><TEXTTYPE:<CONTROL>m><TERME>

 

Yours looks much simpler, and I will give it a try.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...