Opening two individual Chrome windows on different displays at startup

2

I have a Surface Pro 4 with Windows 10 Education x64 plugged into a USB dock that I use as a desktop machine in my office. I have a dual monitor setup on the dock, and use the Surface itself as a third display off on the right.

I've been trying to figure out how to launch two maximized Chrome windows at startup so that each goes to a different URL, and one opens on the main display on the left while the other opens on the center display. According to another article I read and the list on this page, creating two shortcuts in the startup folder with the --new-window, --window-position=X,Y, and --start-maximized switches with the URLs after them SHOULD accomplish what I'm trying to do, and it does successfully open two different windows at those URLs, but the position and maximize switches are ignored. I've noticed that using either of those shortcuts while an existing Chrome window is open will always open it at the same position as the existing window instead of where I've specified in the switch values, and will not maximize the window either.

During my Google-fu, I managed to find this similar question and despite the fact that I'd rather not use app mode, I tried using the command line script included in the answer just to see if it would work the way I'd like. But this unfortunately gives me the same results as using the command line switches. Here are the lines I've tried:

With command line switches

"C:\Program Files (x86)\Google\Chrome\Application\chrome.exe" --profile-directory="Default" --new-window --window-position=0,0 --start-maximized http://www.example1.com

"C:\Program Files (x86)\Google\Chrome\Application\chrome.exe" --profile-directory="Default" --new-window --window-position=1680,0 --start-maximized http://www.example2.com

With javascript and command line switches

"C:\Program Files (x86)\Google\Chrome\Application\chrome.exe" --app="data:text/html,<html><body><script>window.moveTo(0,0);window.location='http://www.example1.com';</script></body></html>" --start-maximized

"C:\Program Files (x86)\Google\Chrome\Application\chrome.exe" --app="data:text/html,<html><body><script>window.moveTo(1680,0);window.location='http://www.example2.com';</script></body></html>" --start-maximized

With javascript and manual window size values to make up for the lack of maximizing

"C:\Program Files (x86)\Google\Chrome\Application\chrome.exe" --app="data:text/html,<html><body><script>window.moveTo(0,0);window.resizeTo(1680,1010);window.location='http://www.example1.com';</script></body></html>"

"C:\Program Files (x86)\Google\Chrome\Application\chrome.exe" --app="data:text/html,<html><body><script>window.moveTo(1680,0);window.resizeTo(1680,1010);window.location='http://www.example1.com';</script></body></html>"

(The two displays from the dock run at 1680x1050, but I'd measured out that the Taskbar is 40px tall so I took that into consideration when I gave the size values)

Is there a more elegant way to accomplish what I'm trying to do? Could one of the other command line switches be overriding the --start-maximized switch? Do you have any suggestions for some better practices?

Thanks!

Trevor Shinn

Posted 2017-05-08T21:35:15.293

Reputation: 21

Did you try to create two different named linking points, one per monitor and start it just with the url as command ? – Tech-IO – 2017-05-08T22:14:23.760

No answers