These are simple toolbar buttons which point to exe files: Excel, Photoshop, etc. When I click on the Lightroom button it briefly flashes to the foreground and then DO (or LR) forces it back to the background. The only one that does that.
I created it in the 'desktop' folder. When I dbl-click the shortcut in explorer the same thing happens. When I do likewise on the actual shortcut on the desktop, no.
Still... I guess there's no way to circumvent this bad behavior and force a program to come back to the foreground?
It depends a bit on how/why Lightroom is losing the focus and where the focus is ending up. There probably is a tool that will fix it, maybe Autohotkey could, but I don't know for sure.
I would ask Adobe for advice since it seems to be happening no matter what launches it, although it could turn out to be another tool confusing things. Anything that changes how windows behave might be involved.
I'm using Lightroom, too. It doesn't happen here, the focus stays with LR. I'm opening Lightroom using a context menu command, which is set for all images, in the file types group "images".
I've got maybe 20 other buttons for major applications, utilities, etc. and they all work perfectly so it's pretty clear that it's just LR.
This actually began happening a while ago when I was running DO 11 and an earlier version of LR. I thought it was something that went sideways on my machine so I (kind of) ignored it, but now that I've built a completely new PC and reinstalled all software it's still there.
I guess I should first go though all my LR settings. I doubt Adobe would help much.
Re: Notepad++. In preferences: File Operations - Double-click on files - open unregistered file types... just enter Notepad++ there for files with no extension, for instance.
In addition, you have to run the NP++ setup as an administrator (in case you're running as a limited account) and then verify that it all works in Control Panel (default programs). It's stubborn. But if you get TXT to work this way I've found that it all works (and I've done this on several machines several times).
I find it easier to have a hack in place so I don't have to register Notepad++ at each application that may open unregistered text files.
I just re-read the Run Method documentation and changed that numeric value to 5. Guess I missed it the first time. Hoping this time it will work as intended.
Edit: @Spokes, if you really don't find a fix for the LR opening on the background, you may try to launch it from a script using that run method.