Move Window to Different Monitors

This question is pretty similar to other posts, but I am not an expert so I don't know how to adapt the others to fit my needs. I have 4 monitors (3 external and a laptop). I would like to use a hotkey to move the front window to a certain monitor - so for example, F16 would move it to monitor 1, F17 would move it to monitor 2, etc. Is there an easy way to do this?

Try the Manipulate a Window action.

Each of these actions would be a separate macro, set with your HotKeys F16-F18
(I don't have a way to test monitor #4)

2 Likes

@bherdrick,

Since the SCREENVISIBLE() function only supports "Main", "Second", and "Third", to handle four screens you would need to use "0", "1", "2", "3".

See SCREENVISIBLE function.

SCREEN( index [number OR name], coordinate )

1 Like

My second screen is a nice 4K where I tend to put 4 windows - in quadrants. I assume one can do the above and then resize to fit in the appropriate quadrant.

You can move and resize in one Action.
Take a look at this example of resizing windows in thirds:

https://forum.keyboardmaestro.com/t/screen-windows-manipulation/18676/7?u=jmichaeltx

Where I used "Front" for the screen, you can use the index for your screen, or just "External".

1 Like

I think I’m going to add this setting up to my HyperKey (Caps Lock) palette - as it’s a global action.

(Sorry to hijack the thread but I think my tangent relevant.)

This is great! Thank you. Any way I can center the window rather than just putting it at left top, like (screen_width - window_width) / 2?

thanks

Try
SCREENVISIBLE(Front,Left) + SCREENVISIBLE(Front,Width)*50% - WINDOW(Width)*50%
SCREENVISIBLE(Front,Top) + SCREENVISIBLE(Front,Height)*50% - WINDOW(Height)*50%

1 Like

This worked perfectly for me. Thank you very much for sharing!