Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Num Lock at the User Sign On Screen 1

Status
Not open for further replies.

Maineflyfish

Technical User
May 13, 2002
10
US
How can I get the Num Lock to come up at the user sign in screen in XP?

I can go to regedit, user, control pannel and change the settings there for the current user, but that doesn't help me at the user log on screen.

Thanks
 
Multiple ways to do this, but remember this only begins working after you set the key the way you want, and then do a restart:

To control how numlock functions, edit the following script as desired, cut and paste into numlock.reg and run it.

REGEDIT5
BLANK LINE GOES HERE
[HKEY_CURRENT_USER\Control Panel\Keyboard]
"InitialKeyboardIndicators"="2"
BLANK LINE GOES HERE

With InitialKeyboardIndicators=2, NumLock is enabled and will retain the settings from the last shutdown. With InitialKeyboardIndicators=0, NumLock is disabled for current user.

Numlock doesn't reflect these setting during the logon phase because at that point, Windows is using the .Default user profile since it does not know which user is logging on. Make the same changes to [HKEY_USERS\.DEFAULT\Control Panel\Keyboard] if you want the numlock state to be consistent throughout.

The best, and non-registry editing method to set InitialKeyboardIndicators, is to set numlock on, then use Alt-Ctrl-Del to log off. It should remember state for the account.

Its usually best to avoid registry hacks if possible. You can use the following Windows Script, name it numlock.vbs, to control numlock:

set WshShell = CreateObject("WScript.Shell")
WshShell.SendKeys "{NUMLOCK}"

For an individual user, copy numlock.vbs to the user's startup folder. To get the script to run for all users, put the script in the Startup folder in the All Users profile.
 
Or to simplify this, on bootup go into the Systems BIOS and set the numlock key setting so it boots up as being on.
 
zoeythecat,

that doesn't work - XP (NT and 2k too) will turn numlock off at the logon screen even if turned on in the bios - unless the registry is changed (I don't know if bcastner's registry hack works as I've always used x-setup from to do this - which defintely does work, and haven't checked the actual registry key concerned).
 
PS - checked x-setup - it does update registry as per bcastner's post.
 
That is strange. I have a few Dell Dimension Desktops. 2 with W2k, 1 with WXP. If I go into BIOS and set numlock to "on" the numlock key is on at bootup. If I set the numlock key to off during bootup it goes off. So I guess each system is different and this is why I thought doing this in the BIOS would work.

 
Actually there is a registry setting you can try modifying.

CAUSE
By default NUMLOCK is set to on.
RESOLUTION
You can modify this setting by editing the registry on the portable computer.

WARNING: Using Registry Editor incorrectly can cause serious, system-wide problems that may require you to reinstall Windows NT to correct them. Microsoft cannot guarantee that any problems resulting from the use of Registry Editor can be solved. Use this tool at your own risk.

Normally, the computer applies the user settings when the user logs on, but it uses the default user profile when it is first turned on, before the user has logged on. To turn this functionality off, the default user settings must be modified. The Keyboard entry contains user preferences as defined by choosing the Keyboard icon in Control Panel. Entries are found under this registry path:
HKEY_USERS\.DEFAULT\Control Panel\Keyboard

InitialKeyboardIndicators REG_SZ Number
Default: 0


Specifies initial values for keys. 0 means that NUMLOCK is turned off after the user logs on; 2 means NUMLOCK is turned on after the user logs on. This value is set when logging off or during shutdown to preserve the state of the NUMLOCK key at that time.

This value can also be changed on a user basis by modifying HKEY_CURRENT_USER\Control Panel\Keyboard and the same registry key.

For more information, see the following Microsoft Knowledge Base article:
 
Actually let me just correct myself and state ==>bcastner< already pointed this all out. Just did not read his post closely enough. I thought it was just as simple as setting the BIOS setting.

 
Knowing that playing in regedit is a dangerous thing, I was hesitant to run any scripts there. But reading the thread, I saw that I always boot up as 'default user' then log in. So I changed the control panel, keyboard setting in regedit default user from =0 to =2 and now XP always boots with numlock on.

bcastner...you da man!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top