Windows Explored

Everyday Windows Desktop Support, Advanced Troubleshooting & Other OS Tidbits

When A GUI Goes Missing (and Worse, It Has No Presence in the Taskbar)

Posted by William Diaz on February 3, 2012


…you might find yourself scratching your head as to why some application seems to not be responding. Normally, when a GUI or an application opens off the screen and cannot be seen, you can just right-click (Shift + Right-Click in Windows 7) the task in the Taskbar and Select Move and drag it back into focus. This area off the screen can be thought of as the virtual desktop area. But what if the GUI does not have a presence in the Taskbar?

For example, we have an in-house developed GUI that connects Word, Excel, and PowerPoint to our document management system for opening or saving documents to it. Unfortunately, the GUI doesn’t have a presence in the Windows Taskbar. Because of this, every once-in-a-while when someone opens the GUI via Save or Open, it fails to appear and the application that it was opened from acts as if it has become unresponsive. Looking in the Task Manager, though, reveals the application is, in fact, running:
image
So how do you get it back1?

These type of Application-GUIs settings are stored in the Windows Registry and likely somewhere to be found under HKCU\Software\AppNameOrVendor\SomeSubKey. Hopefully you can often find these named as simple REG_DWORD2 types like XPos and YPos or something similar (hint: don’t limit a reg search to include Match whole string only):
image
When I encounter this issue, often times one of data values contains a value that falls outside the x,y range of the physical screen(s):
image
If you were to visualize XPos 1520 x YPos 979 for our Open DMS GUI on our standard 1280 x 1024 displays, it would look something this:
image
(Figure drawn in Windows 7 Paint!)

To deduce how this happened, imagine our user had a 1920 x 1200 monitor and for whatever reason went to a 1280 x 1024. The x,y coordinates haven’t changed but the physical desktop area has become smaller and now the Open DMS GUI opens off the screen. Another scenario would be where a user had a high screen resolution and later changed to something lower. Also toggling between primary and secondary monitors and repositioning them or removing one of the monitors could cause this if the x,y coordinates resides on the other monitor.

In some cases, you can encounter negative x,y coordinates. This is actually normal because you can position your secondary monitor to the left of your primary one:
image
Using Remote Desktop could also be the cause for this, e.g. you connect with 1280 x 1024 to a workstation that has a dual monitors or a very large high resolution monitor and the x,y coordinates for the GUI reside outside your connecting resolution.

If locating the x,y coordinates of Window becomes a challenge, you might be able to find the key and associated values using Process Monitor. So, lets say our missing Window doesn’t have a presence in the Taskbar and it has gone missing. I’m using the OneNote Side Note, which does have a presence but lets pretend it doesn’t. Setting a filter on the process onenote.exe, registry operations only, where the path contains HKCU, and a RegQueryValue result gives us:
image
Note the data values. WindowPosLeft 2564 and WindowPosRight 2933 tell us its opening on the second monitor to the right of the primary on the x plain, and also that the window is 369 pixels wide. The Top and Bottom values tells where on the y plain it starts and ends, as well as how many pixels it is in height.

Moving the window to the primary monitor and then exiting it, writes the new position values to the registry:
image
Here’s  couple good resource links:
http://www.flounder.com/virtual_screen_coordinates.htm
http://blogs.technet.com/b/mrsnrub/archive/2009/08/31/invisible-windows.aspx


1 By the way, if you were to encounter a situation like this in the middle of a save process and you cannot reposition the save dialog, for example, simply hit ESC to cancel the dialog and return to your app instead of giving up, killing it and losing changes.

2 If you’re unlucky, the coordinates could reside within some binary data string instead, making it all the more harder to find.

Advertisements

One Response to “When A GUI Goes Missing (and Worse, It Has No Presence in the Taskbar)”

  1. […] mistake and maybe I could find its x,y coordinates in the registry (which I already covered in an earlier post). I started the procmon trace after opening Visio, grabbed the Menu Bar, dragged it outside the […]

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

 
%d bloggers like this: