Jump to content
LaunchBox Community Forums

Big Box losing focus within 7 seconds of booting/launching/starting.


playab0yyy

Recommended Posts

See attached video and pictures. PC boots straight into Big Box. If I'm standing in front of it while it boots, I'll typically tap a button to skip the intro video. Anytime I do this upon initial boot, Big Box loses focus within about 7 seconds of it starting up. Had this problem come up once before and at that time, under the Focus Assist settings in Windows, I deselected "Show me a summary of what I missed..." and that seemed to have solved the problem at that time. Couple months later and the problem is back now. The only things I did recently were install Visual Pinball as an emulator (along with some games, and everything there is working great) and some recent Windows updates. I can't confirm any of those are what led to the problem, but those are the only recent changes. Very minimal startup apps and focus assist completely off. Nothing else showing when I alt-tab and nothing additional in the taskbar after exiting BB. Again, this only happens upon initial boot. If I boot up, exit Big Box, then restart Big Box (without restarting the PC), the problem does not happen. Note: This is not the issue mentioned in another forum post about losing focus when exiting a game. I tried the ahk file with no luck. Update: I've been uninstalling all the BS little apps that Windows installs (Groove Music, Messaging, Movies & TV, Paint 3d), basically everything I don't need. I also clicked on the apps that it doesn't allow me to uninstall (Edge, Store, Camera, Alarms & Clocks) and went into them and turned off "Background apps", whatever that means. So far the problem is gone. I have no idea what did it, but I guess something in there was doing it. Not really confident in this solution. Really wish I could pinpoint the problem. If anyone has experienced this and is familiar with a specific solution, I'd love to hear it. Thanks for your time.

IMG_2780.JPG

IMG_2783.JPG

Edited by playab0yyy
Link to comment
Share on other sites

  • 2 years later...
  • 10 months later...

Thanks for taking the time to respond to this 👍. When booting directly into Bigbox my cabinet would sometimes loose focus and I would have to use a mouse. Adding a startup video that lasts 11 seconds appears to have fixed my problem. Thank You, Thank You, Thank you!!!

Link to comment
Share on other sites

  • 2 weeks later...
  • 5 months later...

This is what I did to work out what was stealing focus after BigBox loads at boot-up:

Create a file called activewindow.ps1 with the following code:

Add-Type  @"
 using System;
 using System.Runtime.InteropServices;
 using System.Text;
public class APIFuncs
   {
    [DllImport("user32.dll", CharSet = CharSet.Auto, SetLastError = true)]
   public static extern int GetWindowText(IntPtr hwnd,StringBuilder
lpString, int cch);
    [DllImport("user32.dll", SetLastError=true, CharSet=CharSet.Auto)]
   public static extern IntPtr GetForegroundWindow();
    [DllImport("user32.dll", SetLastError=true, CharSet=CharSet.Auto)]
       public static extern Int32 GetWindowThreadProcessId(IntPtr hWnd,out
Int32 lpdwProcessId);
    [DllImport("user32.dll", SetLastError=true, CharSet=CharSet.Auto)]
       public static extern Int32 GetWindowTextLength(IntPtr hWnd);
    }
"@
 
while(1)
{
$w = [apifuncs]::GetForegroundWindow()
$len = [apifuncs]::GetWindowTextLength($w)
$sb = New-Object text.stringbuilder -ArgumentList ($len + 1)
$rtnlen = [apifuncs]::GetWindowText($w,$sb,$sb.Capacity)
write-host "Window Title: $($sb.tostring())"
sleep 1
} 

Then:

  • Open LaunchBox.
  • Click: Options > General > Startup Applications
  • Add application:
    • Application Path: C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe 
    • Command-Line Parameters: The path/name of your ps1 file created above.
    • Start With: BigBox
  • Reboot

When BigBox loads, wait until it loses focus, then click to give it focus and exit.
You should see a command prompt window with a 1s log of the applications which have focus.
This should help you identify what is stealing the focus.

In my case it was a remote control application called SplashTop. I couldn't stop the behaviour so I reverted to the longer start-up video "solution". You may be more lucky!

I hope that helps.

Credit to: Justin Rich (https://social.technet.microsoft.com/Forums/en-US/c3cd3982-ffc5-4c17-98fc-a09c555e121c/get-all-child-window-titles?forum=winserverpowershell) for the Powershell.

  • Like 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...