Jump to content

T-12 (cmdlines.txt) & registry setting for only 1 user


Recommended Posts

Hi All,

I've been running into a little problem again. At T-12 or T-13 I'm importing registry settings through runonceex and am trying to import email accounts through runonce, however since HKCU is set to the current default user profile, every user on the system has the email accounts imported. Even if I delete the RunOnce setting from the .DEFAULT user profile it still gets processed when a different user logs in.

I have created multiple setup.cmd files and would like to be able to import email accounts from these setup.cmd files for only 1 user without having to use [GuiRunOnce] in winnt.sif.

So my question is: How can I import email accounts to only 1 user through the .cmd files.

Thanks for any help.. :D

Edited by dreamline
Link to comment
Share on other sites


If it is just one workstation that is shared by several people, each with their own profile, and they are not logging in through a server, then I would think that a batch file that runs the first time each user logs in might be one possible solution. It would need to identify the currently logged in user, then run the appropriate user.cmd file which would import their personal email settings into the HKCU.

For Example - add this key at T-12 to integrate it into the default user profile.

"HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce" /ve /d "UserRunOnce.cmd"

Then create individual cmd files for each user named after their login name ie TSmith.cmd, JDoe.cmd, etc

Then create a UserRunOnce.cmd batch file similar to this one

UserRunOnce.cmd

Call %UserName%.cmd

Exit

When a new user logs in, the UserRunOnce batch file will run once, and call their personal cmd file, and then remove itself from their registry profile.

Just a 4am suggestion that might point you in the right direction.

Edited by Rich_Weiss
Link to comment
Share on other sites

Thank you Rich,

That might be a solution indeed. :) Thanks for pointing me in the right direction. At the moment I've created a runonce script and that works smoothly, the problem is however with the identities. At system installation the email identities are not set yet. However I solved that by using GuiRunOnce. I'm not sure if that'll work for all users too, but i'm going to test it. It seems to work for system installation though, now i'm going to test guirunonce to see if it's working for all users too. If so then my problem is solved..

Thanks for the tip.. :D

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...