Opening Multiple file windows to specific location

Get help with using AutoHotkey and its commands and hotkeys
ItsJrod
Posts: 3
Joined: 21 May 2019, 16:04

Opening Multiple file windows to specific location

21 May 2019, 16:08

I wanted to know if there is a way to open two text files, one to the left hand side of my screen and one to my right, at the same time.

Thanks!

EDIT: I guess my question should be refined to: I am having trouble using WinMove for multiple windows. Here is what I have:

Code: Select all

Run, Notepad TextFile1.txt
WinWait, Notepad
WinMove, 0,0

Run, Notepad TextFile2.txt
WinWait, Notepad
WinMove, 400,400
This is resulting in only TextFile1.txt being opened, and it is just opening at the last remembered location.
Last edited by ItsJrod on 22 May 2019, 09:25, edited 3 times in total.
User avatar
elModo7
Posts: 104
Joined: 01 Sep 2017, 02:38

Re: Opening Multiple file windows to specific location

22 May 2019, 04:19

You can open one, wait for notepad to be opened and then with win key + left arrow you can have it move to the left.
Then open another one, wait for notepad, repeat same combo with right arrow.
:beer:
ItsJrod
Posts: 3
Joined: 21 May 2019, 16:04

Re: Opening Multiple file windows to specific location

22 May 2019, 08:42

elModo7 wrote:
22 May 2019, 04:19
You can open one, wait for notepad to be opened and then with win key + left arrow you can have it move to the left.
Then open another one, wait for notepad, repeat same combo with right arrow.
This would work for snapping them, but I want to specify an exact position and window size so that I can still see the center of the screen.
Sam_
Posts: 106
Joined: 20 Mar 2014, 20:24

Re: Opening Multiple file windows to specific location

22 May 2019, 10:35

ItsJrod wrote:
22 May 2019, 08:42
elModo7 wrote:
22 May 2019, 04:19
You can open one, wait for notepad to be opened and then with win key + left arrow you can have it move to the left.
Then open another one, wait for notepad, repeat same combo with right arrow.
This would work for snapping them, but I want to specify an exact position and window size so that I can still see the center of the screen.

Code: Select all

Run, Notepad.exe, , , PID1
WinWait, ahk_pid %PID1%
WinMove, ahk_pid %PID1%, , 0, 0

Run, Notepad.exe, , , PID2
WinWait, ahk_pid %PID2%
WinMove, ahk_pid %PID2%, , 400, 400
ItsJrod
Posts: 3
Joined: 21 May 2019, 16:04

Re: Opening Multiple file windows to specific location

22 May 2019, 13:52

Sam_ wrote:
22 May 2019, 10:35
ItsJrod wrote:
22 May 2019, 08:42
elModo7 wrote:
22 May 2019, 04:19
You can open one, wait for notepad to be opened and then with win key + left arrow you can have it move to the left.
Then open another one, wait for notepad, repeat same combo with right arrow.
This would work for snapping them, but I want to specify an exact position and window size so that I can still see the center of the screen.

Code: Select all

Run, Notepad.exe, , , PID1
WinWait, ahk_pid %PID1%
WinMove, ahk_pid %PID1%, , 0, 0

Run, Notepad.exe, , , PID2
WinWait, ahk_pid %PID2%
WinMove, ahk_pid %PID2%, , 400, 400
This is solid, thank you!

Return to “Ask For Help”

Who is online

Users browsing this forum: Chunjee and 270 guests