Replacing the shell on WinXP

From: Mike Warren (miwa_at_NOSPAMiprimus.com.au)
Date: 12/07/03


Date: Sun, 7 Dec 2003 20:19:09 +1000

Hi,

Sorry for the long post. I am at my wits end as I have been
trying to find a solution to this problem for nearly 12 months.

I need to replace explorer with my program as the windows
shell but have a problem...

I use the following registry entry to set the shell to my program:

HKEY_LOCAL_MACHINE
  \Software
    \Microsoft
      \Windows NT
        \CurrentVersion
          \Winlogon Shell=MyProgName.exe

When Windows starts up, my program starts fine but the
windows logon screen covers my app and won't go away
for another 25 to 30 seconds. This is the light blue screen
with darker blue bands at the top and bottom that has a small
windows logo on it and says "Loading Personal Settings...".

I am able to overcome this delay by setting "LogonType=1"
(normally 0). This causes WinXP to boot more like Win2K
and doesn't show the blue screen.

The problem with this is that a dialog opens at start-up requesting
a password even though a password is not set.

This in turn can be overcome by setting "AutoAdminLogon=1".
However, this setting will very intermittently set itself back to
"AutoAdminLogon=0" and requires the enter key to be pressed
to continue. I am unable to find a pattern to when this happens
but may be related to the power cord being pulled out of the
computer. I have tried explicitly resetting this key on every boot
but it doesn't seem to help.

When the password dialog opens, the computer is effectively
dead as there is no keyboard or mouse connected to it and
restarting will not fix it. This means a service call as the customer
has no easy means to connect a keyboard to the computer. And
besides, the monitor is switched off until my program is running
so all the customer knows it that the machine did not start.

I can think of some possible cures but haven't been able to work
out how to implement any of them:

1/ Communicate with WinLogon.exe in the same way explorer
must when it is the shell. I am guessing that WinLogon.exe in
generating my problem screen as it is the only program to
showup in a process list other than my program.

(From my test program)
WINLOGON.EXE - NetDDE Agent - NDDEAgnt
SHELLTEST.EXE - Windows XP Shell Test Program - TForm1
SHELLTEST.EXE - - TPUtilWindow
SHELLTEST.EXE - Shelltest - TApplication

2/ Somehow generate a Ctrl+Alt+Del key sequence. This will
close the problem screen and start task manager which I could then
close by sending it a message from my program. (I have tried starting
task manager from my program but it doesn't remove the problem
window.)

3/ Use the method I am using now and somehow generate an
"Enter" keypress. This would have to be done with some custom
hardware pretending to be a keyboard as I don't think I can start
a program before the password window opens.

I have written a small test app that shows the problem and can
post it to the attachments group if anyone is interested.

Please help. Even if you can suggest where I might be able to find
some information on how WinXP handles this area.

-Mike



Relevant Pages

  • My recent Epiphany about operating systems
    ... In Winblow$, the release & bundling of IE was purposely as crippleware, virus, & bug delivery system 2 trap people into constantly 'upgrading'. ... A simple comparisson of Windows 95 side-by-side with the final Windows ME & various IE 'upgrades' illustrates how the supposedly 'new & improved' stuff is actually about 1/5 the speed, ... The OS Kernels are designed to require constant patching or nothing runs properly when 'upgrading' softwares. ... Just like M$ writes Windoze 2 B full of bugs, so they can keep selling the same crap over & over "oh but we fixed it this time" - yeah right:)) I am still using the shell from Windows95. ...
    (freebsd-questions)
  • Re: My recent Epiphany about operating systems
    ... In Winblow$, the release & bundling of IE was purposely as crippleware, ... & bug delivery system 2 trap people into constantly 'upgrading'. ... simple comparisson of Windows 95 side-by-side with the final Windows ME & ... AND fast shell that Microsoft has released. ...
    (freebsd-questions)
  • Re: My recent Epiphany about operating systems
    ... simple comparisson of Windows 95 side-by-side with the final Windows ME & ... properly when 'upgrading' softwares. ... but the configuration to be a complete nightmare so as to create a need for ... AND fast shell that Microsoft has released. ...
    (freebsd-questions)
  • Re: How to change my c++ programs icon?
    ... to write console applications that run on a text-based shell than ... That "Linux" has useful features Windows is lacking clearly ... who believe that console applications provide some welcome simplicity ... Microsoft are the leaders of the "anything a console app can do, ...
    (comp.os.linux.development.apps)
  • Re: Custom shell window management
    ... have multiple non-modal windows, then click on the 'background' shell ... app, all of the spawned windows are 'hidden' behind the shell. ... that seem common to custom shell creation. ...
    (microsoft.public.windowsxp.embedded)