Author Topic: Hotkey/command help - Select specific window/program?  (Read 2052 times)

varxtis

  • Newbie
  • *
  • Posts: 7
Hotkey/command help - Select specific window/program?
« on: June 14, 2021, 09:17:14 PM »
Lets say you have 10 windows/programs open. Some are open, some are minimized, but all active. I know that you can toggle through active programs via Alt+tab or Alt+Ctrl+Tab, but is there a way to setup a command to select a specific active window/program? I want a command to select Media Player Classic. It's active, but paused in the background type of thing. And sorry if I'm using "active", "open", "window" and "program improperly. But I hope my goal makes sense. Still learning.

Pfeil

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 4782
  • RTFM
Re: Hotkey/command help - Select specific window/program?
« Reply #1 on: June 14, 2021, 09:22:46 PM »
That is what the "Send command to this target:" option is intended for.

Note that the window will be brought to the foreground, which is a necessity as Windows sends normal keyboard input to the window that currently has focus.

Also note that applications or windows that are "minimized" to the system tray cannot be brought to the foreground ("minimizing" to the system tray is not actually supported by Windows, rather applications hide their window and show a system tray icon to produce the effect)

varxtis

  • Newbie
  • *
  • Posts: 7
Re: Hotkey/command help - Select specific window/program?
« Reply #2 on: June 15, 2021, 07:20:27 PM »
So, I basically deleted the original reply as I was making an invalid argument. You were right. I just executed it wrong. There is one thing that I was right about though, at least for this particular scenario, Apps/programs wont respond to a command or "come to the foreground" if its minimized. VoiceAttack seems to require that the program at least be in a restored state, even if its in the background. To fix this you can just at a command to the front of a sequence that pulls the program up first. The VoiceAttack 1.6.5-Profile.vap has a command to do just that. You just have to change the target program and design verbal command.

Regarding Selecting an app that is in background or minimized: A user on Tenforums brought these to my attention

Currently, Im just interested in controlling iTunes and Media Player Classic verbally from anywhere else in the room. Though my original question is still of interest to me, for now what I'm doing is
1. Pin MPC to the no. 1 spot of the windows task bar
2. Set the first command in the execution sequence to key press "Win+1"
3. Set the second command in the execution sequence to Key Press "Left Shift + Left Win + Right"
**
Press Left Win+1 keys and hold for 0.1 seconds and release
Press Left Shift+Left Win+Right keys and hold for 0.1 seconds and release
**

I have 3 monitors. This makes it so MPC will be restored, then shift to the next monitor/desktop each time I say the command. If it's on monitor 3, it will just cycle back to 1. This command covers the app whether it's minimized or in restored state, but in the background.

Thank you very much for your help. As I Said, still interested in my original goal, so please keep me in mind if you think of anything. Im pretty impressed with your knowledge base and understanding of the program. Ive come across a lot of threads here in my search, and 9 out of 10 of them are resolved by you (b^_^)b
Also, is that Willem Dafoe?
« Last Edit: June 15, 2021, 08:30:16 PM by varxtis »

Pfeil

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 4782
  • RTFM