2

I use Displayfusion to move windows to certain areas of the screen on open. When Discord opens, for example, DF moves it to my 2nd monitor. Both DF and Discord run at startup, but Discord finishes opening before DF can, meaning Discord never opens on my second display.

I'd like to ensure Displayfusion opens before Discord opens, but I'm not sure how to change the order in which things open at startup. If I can't, could I not just delay when Discord opens?

1
  • One simple way would be to launch both processes from a batch file and call that as a startup process. In that batch file, launch the one, sleep for X seconds (you will need to manage this), then launch the second process and exit. It is sloppy but should work. You (of course) will need to remove the initial startup items. With some windows programming skills, you could create a simple app that watches for the window creation before launching the second process. Commented Jan 7, 2022 at 17:35

2 Answers 2

2

You have many possible solutions.

Perhaps the simplest one would be to remove these items out of start-up and run them from the Task Scheduler, where the "At log on" trigger has a "Delay task for" parameter.

See How to delay program startup with Task Scheduler on Windows 10/8/7.

1

Looking into the the two products mentioned, if configured to run at start-up they make use of the "Run" key for the current user.

In this case they values are as follows:

[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run]
"Discord"="C:\\Users\\<user>\\AppData\\Local\\Discord\\Update.exe --processStart Discord.exe"
"DisplayFusion"="\"C:\\Program Files (x86)\\DisplayFusion\\DisplayFusion.exe\""

In the documentation referenced above it says:

If more than one program is registered under any particular key, the order in which those programs run is indeterminate.

Therefore you will need to manually orchestrate the starting of these two applications to get one to start before the other in a deterministic way.

One option would be to disable both applications from starting after logon for the current user using Task Manager: Disable start-up using Task Manager

This disabled the processes from being launched at start-up by configuring the following registry values under:

HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\StartupApproved\Run

Task Manager Run key management

Using this method, even if the application re-created the 'Run' key values on update for example, they should remain disabled for the user in question.

I would suggest then create a batch file referenced from the same 'Run' key that launches the applications in the preferred order.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .