Dedicate a PC to a single application

I want to do something that seems so obvious, and so common, that I'm surprised it's so difficult to figure out how to do.  What I want is that when a user logs into a Windows XP PC they are thrown into an application and can access nothing else on that PC.  They can't get to the Windows Shell or anything else, just run the application.  And when they exit the application they are automatically logged off.  

Running the app is easy enough via a logon script, but that still leaves the user with access to the Windows Shell.

So, how does one truely lock a user into a single application?
Who is Participating?
GranModConnect With a Mentor Commented:
PAQed with points refunded (500)

Community Support Moderator
Lee W, MVPTechnology and Business Process AdvisorCommented:
You replace the shell with the application.  It's a registry setting.
hberensonAuthor Commented:
That's what I suspected.  Any idea what the registry setting is?
Cloud Class® Course: Amazon Web Services - Basic

Are you thinking about creating an Amazon Web Services account for your business? Not sure where to start? In this course you’ll get an overview of the history of AWS and take a tour of their user interface.

Lee W, MVPTechnology and Business Process AdvisorCommented:
the Shell key in HKLM/SOFTWARE/Microsoft/Windows
hberensonAuthor Commented:
Anyway to force a logoff when the application exits?  Right now if I just make it the shell when the user exits they still have a live windows session.
Lee W, MVPTechnology and Business Process AdvisorCommented:
Hmmmm... that's a good question.  This isn't an in-house app is it? One that maybe you could reprogram to auto-logoff?  I'll see what I can dig up on that though...
hberensonAuthor Commented:
It's Quickbooks actually.  I imagine I could write an application that does nothing but launch quickbooks, wait for it to exit, and then logs off.  I want hoping for something that didn't require app development.
hberensonAuthor Commented:
Because of the need to have a logoff occur when the user exits the application we couldn't use the approach that Lee suggested.  Instead I created a logon script that runs the application and waits for it to exit, then logs off.  And I set the registry so that the script is run synchronously.  I borrowed bits of the script from one I found on the net, but it needed some changes.  For example, you run QBW32Pro.exe however it launches another process and exits.  So you have to wait for the "real" process to exit.  The script is below:

Const EWX_LOGOFF = 0
strComputer = "."
Set objWMIService = GetObject("winmgmts:\\" & strComputer & "\root\cimv2:Win32_Process")
errResult = objWMIService.Create("C:\Program Files\Intuit\QuickBooks 2005\QBW32Pro.exe", null, null, intQBID)

Set objWMIService = GetObject("winmgmts:\\" & strComputer & "\root\cimv2")

Set colProcesses = objWMIService.ExecNotificationQuery _
    ("Select * From __InstanceDeletionEvent " _
            & "Within 1 Where TargetInstance ISA 'Win32_Process'")

Do Until i = 999
    Set objProcess = colProcesses.NextEvent
    If objProcess.TargetInstance.ParentProcessID = intQBID Then
      if objProcess.TargetInstance.ExecutablePath = "C:\Program Files\Intuit\QuickBooks 2005\qbw32.exe" Then
              Exit Do
      End If
    End If

Set wmi = GetObject("winmgmts:{(Shutdown)}")
Set objSet = wmi.InstancesOf("Win32_OperatingSystem")
For Each obj in objSet
      Set os = obj
      Exit For
os.Win32Shutdown EWX_LOGOFF

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.