Closed Gazareth closed 4 years ago
I haven't got Visual Code so can't try it directly. If it's opening correctly (but not on the correct desktop), you could try the launchOnDesktop flag. Which I seem to remember switches to the desktop and then runs it, this won't allow you to change the size or anything though.
The better solution is this from the help:
'waitForClass' | This is a good option for non-standard processes. You can use the Spy++ tool to find the window class. See the example file for a couple of useful examples
If you can work out the window class for the visual code window, the script should correctly wait for a new window of that class and then act on that window.
There is a simple utility I found here: https://www.nirsoft.net/utils/winlister-x64.zip
This will list the open windows and there window classes. So just start Visual Code and then run this utility to get the name of the window class.
Thanks for that, very helpful!
It has allowed me to fix some other issues I was having with firefox, TIDAL and WhatsApp.
This problem still persists though where FileStarter seems to want to keep hold of Electron/VS code as a process, and continues receiving output from them. If I try to close the powershell window, it says something about the render process failing, and VS code exits (presumably not so gracefully).
If I run code MyTextFile.txt
in a cmd prompt or powershell, it will open up VS Code with no issues. Seems to be the way FileStarter wants to launch it that is causing an issue. 😕
I've commited a fix. VisualCode was hanging on to the powershell console (which I now close)
Hi there I like your software so thanks for making it.
Issue is when trying to run Microsoft Visual Studio code, which is an Electron process so I believe it is run by some kind of trigger command window which instantly disappears.
I've tried setting the related options
waitForProcessToClose
andhassplash
to true but to no avail.