Logon script - aim at individual user not group
Hi all,Ive configured a logon script that i want to aim at a specific user. In the past i have used the ifmember.exe app that can let you specificy a group for the logon script to run for. How cani do this for an individual user. I dont want to use group policy, or OU's, etc. I want this to strictly be for a batch logon script.Thanks.
July 21st, 2009 4:28am
Hi gbug,
Thank you for posting here.
According to your description, I understand that you want to assign a batch logon script at a specific user.
To assign a logon script to a local user, please follow these steps:
1. Click Start , and then click Control Panel .
2. Double-click Administrative Tools , and then double-click Computer Management .
3. In the console tree, expand Local Users and Groups , and then click Users .
4. Click the user account that you want to work with.
5. Click Action , and then click Properties .
6. Click the Profile tab, and then type the path and file name of the script under Logon script .
7. Click Apply , and then click OK.
8. Done.
The following information can help you share the folder correctly:
The default location for local logon scripts is the %SystemRoot%\System32\Repl\Import\Scripts folder. You must share this folder by using the share name netlogon .
If you do not want to create the netlogon share in the default location, place the script in access to during logon. It is any folder that the user has recommended that this folder be shared.
To assign a logon script to a domain user, please follow these steps:
1. Logon a domain controller as an administrator.
2. Open Administrative Tools, click Active Directory Users and Computers.
3. Locate a specific user in the Users or OUs, double click this user.
4. Select the Profile page, type in the script name into Logon Script text box.
5. Click Apply and OK
6. Copy the relative users logon script file into this DCs \\localhost\netlogon\ path, precede the file name with the relative name, for example, Clerks.bat or Our_users \ user_1 .cmd
7. Done.
Free Windows Admin Tool Kit Click here and download it now
July 21st, 2009 3:02pm
Hi gbug,
Thank you for posting here.
According to your description, I understand that you want to assign a batch logon script at a specific user.
No, you've missed what i was asking for.I have one logon script for my entire organisation. From within there, i want to aim a specific part of the script at a specific user. You can do this for AD security groups using the Ifmember.exe tool. However, i only want to aim a certain part of this logon script at a specific user. I dont want to change the logon script name or location for individual users. I want to have ONE logon script for everyone, and a particular line of that script aimed at a specific user.
July 22nd, 2009 1:53am
Hi Gbug,
According to your explanation, you would like to know how to customize the logon script so that a code line is run only when a specific user logs on. You may use the %UserName% environmental variable to retrieve the currently logon user. For example, the following line in a batch file will start NotePad when the current logon user is "Administrator".
if "%username%" == "Administrator" start notepad.exe
As the issue is related to development/coding, I have to say that we are not the best support resource for it. If you need any further help on customizing the logon script, I would like to suggest that you initial a new thread in one of the MSDN forum for better and accurate answer to the question. The community members the support professionals there are more familiar with coding and can help you in a more efficient way.
MSDN forum
http://social.msdn.microsoft.com/Forums/en-US/categories/
Free Windows Admin Tool Kit Click here and download it now
July 22nd, 2009 5:49am