views:

840

answers:

4

i have replaced windows shell with my application it worked perfectly, after closing my application i have to launch windows explorer with the following piece of code

Code to start explorer

Process.Start(@"c:\windows\explorer.exe");

Registry key i have used to replace shell

HKEY_Local_Machine\Software\Microsoft\WindowsNT\CurrentVersion\WinLogon\Shell

it doesnt show taskbar and start menu, it just shows mydocuments folder. I need start menu and taskbar while after explorer started

A: 

My guess is that since explorer isn't defined as the shell, it won't run as the shell. I think that you'd have to change the registry settings to make explorer the shell again before you run it.

Chris Thompson
i have to launch explorer from my application. without changing registry. because my application added to windows shell and started successfully
JKS
A: 

So, as you wrote you replaced the shell in the registry with your own version. So it's up to you to show a start menu, etc. If you like to start a explorer and let it act as a shell, go on and replace the entry in the registry with the old one.

Due to the fact, that you like to be the shell again, next time windows starts, maybe the following trick will do it:

Prerequisities:

  • Place your program in registry as shell and start windows
  • Your program runs and wants to start explorer as shell

Action to to:

  1. Replace entry in registry against entry containing explorer as shell
  2. Start the explorer
  3. Replace entry in registry back to your app as shell programm
  4. Wait till next boot...
Oliver
A: 

You will probably have to kill the existing shell process (i.e. your app) before starting explorer again.

Kragen
A: 

Process.Start("iexplore.exe");

That oughta do it...

baeltazor