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 SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

at user logon, auto adding a reg hack

Status
Not open for further replies.

smlull

MIS
Aug 17, 2002
40
0
0
US
I have 20 Win2000 pc's that I'd like to add a reg hack to each time a user (new user) logs in. I'd like to make this silent and none seeable by anyone.

Any Ideas,
Thanks In Advance.
Scott
 
Courtesy of
just have it run a batch file importing the registry changes


HOW TO: Run a Logon Script Once When a New User Logs On
The information in this article applies to:
Microsoft Windows 2000 Advanced Server
Microsoft Windows 2000 Server
Microsoft Windows 2000 Professional

IN THIS TASK
SUMMARY
Configure a Script to Run Once When a New User Logs On
REFERENCES
IMPORTANT: This article contains information about modifying the registry. Before you modify the registry, make sure to back it up and make sure that you understand how to restore the registry if a problem occurs. For information about how to back up, restore, and edit the registry, click the following article number to view the article in the Microsoft Knowledge Base:
Q256986 Description of the Microsoft Windows Registry
SUMMARYThis article describes how to configure a logon script, or program to run one time. These steps apply only to new users who have never logged on to the computer. If a user already has a local user profile, or a roaming profile, the script will not run.

back to the top
Configure a Script to Run Once When a New User Logs On
WARNING: If you use Registry Editor incorrectly, you may cause serious problems that may require you to reinstall your operating system. Microsoft cannot guarantee that you can solve problems that result from using Registry Editor incorrectly. Use Registry Editor at your own risk.

The Default User profile is created when Windows is installed. The first time a user logs on to a workstation (or domain), the Default User profile is copied to the user's profile.

To configure a script to run one time when a new user logs on, follow these steps:
At a command prompt, type regedt32.exe.
Click HKEY_USERS on the Windows menu.
Click HKEY_USERS in the left panel, and then click Load Hive on the Registry menu.
Locate the Profilepath\Default User\Ntuser.dat file, and then click Open. Give the hive a name such as "Test" when you are prompted.

NOTE: The Ntuser.dat file is hidden. If you are unable to locate, or load the Ntuser.dat file, in Windows Explorer, on the Tools menu, click Folder Options, and on the View tab, make sure that Hide file extensions for known file types is not selected, and that Show hidden files and folders is selected. For additional information about Windows 2000 User Profile storage, click the article number below to view the article in the Microsoft Knowledge Base:
Q228445 User Profile Storage in Windows 2000
Locate the following registry key where "test" is the name given to the loaded Ntuser.dat hive:
HKEY_USERS\Test\Software\Microsoft\Windows\CurrentVersion\Runonce
Click the Runonce key in the left pane, and then click Add Value on the Edit menu.
Enter the following information for the new value:
Value name: test.bat (you can name this anything)
Data Type: REG_SZ
String: c:\test.bat (this is the path to the file, and the file name)
Click the "Test" hive, and then click Unload Hive on the Registry menu.
As mentioned above, this will run for a user who does not already have a user profile. Any local User Profiles will be listed on the User Profile tab in System properties.
The only thing you have to know is how to find the answer.

If it weren't for users, computers would work just fine....If computers worked I'd be unemployed!
 
Thanks! I did find out the answer and I do really appreciate the response.

Scott
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top