How to click OK on a dialog on another desktop?

3

1

For months i have had a Windows Update stall. For months i've seen Windows Installer stuck trying to do something:

enter image description here

Every time i reboot it leaves an orphaned folder in the root of my C: drive:

enter image description here

i see that Document Explorer was launched by Windows Installer with a /setup command line option:

"c:\Program Files (x86)\Common Files\Microsoft Shared\Help 8\dexplore.exe" /setup /log "C:\Windows\TEMP\VS1.tmp"

Today i finally looked into it, and the problem is that Document Explorer is stuck showing a message box:

enter image description here

How can i click OK on a dialog box, that is running under the context of NT AUTHORITY\SYSTEM, and probably running on another desktop?

Note: Windows has provided no mention that a service is showing a message box - offering to let me switch to Session 0 desktop.

See also

Ian Boyd

Posted 2011-07-25T11:14:17.967

Reputation: 18 244

Are you just trying to solve this one problem, or as a general rule? I would just download the problem patch, extract it so I can see more of what it is doing, and install it manually. – KCotreau – 2011-07-25T11:56:54.627

Process Explorer should show you the session ID the process belongs to, then you can run elevated psexec -desi tscon <sessID> to connect yourself to the other session... (before you do that, ensure you have a way back: psexec -desi <sessID> cmd)

– user1686 – 2011-07-25T12:01:18.113

I'd abandon ship. An error as crazy as this causing even more errors couldn't be corrupting more than just the Installer. – surfasb – 2011-07-25T16:17:58.093

@grawity: It looks promising. It's Session 0. psexec -desi tscon 0. Unfortunately all that happens in a console window flashes up; i cannot read what i presume is an error message. But my console does say tscon started on HARPAX with process ID 7460., but the process closes immediately. – Ian Boyd – 2011-07-26T02:55:22.463

@Ian: Hmm, try removing -de options (psexec -si tscon 0). It should run the process in the same console. (I'm not sure why I added -de in the first place.) – user1686 – 2011-07-26T09:10:45.837

Answers

1

I found one way to do it; although I'd like to see grawity's work.

A MessageBox is being shown on the desktop of Session 0. Windows Vista and 7 have a service that looks for anyone showing a dialog box on the "secure" desktop, and offer to let you switch to it.

I was not seeing any notification, because the Interactive Services Detection service was not running (in Windows 7 it defaults to manual startup).

Service name: UI0Detect
Display name: Interactive Services Detection
Description: Enables user notification of user input for interactive services, which enables access to dialogs created by interactive services when they appear. If this service is stopped, notifications of new interactive service dialogs will no longer function and there might not be access to interactive service dialogs. If this service is disabled, both notifications of and access to new interactive service dialogs will no longer function.
Path to executable: C:\Windows\system32\UI0Detect.exe

You can manually start this service by running (from an elevated command prompt):

>sc start ui0detect

As soon as I did that a notification appeared. It had detected a message box and offered to let me switch to the secure desktop:

enter image description here.

After I clicked OK on the offending dialog box, I was able to return to my desktop by clicking the I'm done button:

enter image description here

It would still be good to find a way to be able to switch to the Session 0 "secure" desktop whenever I wanted to - not just when the Interactive Services Detection services detected an interactive service.

Ian Boyd

Posted 2011-07-25T11:14:17.967

Reputation: 18 244