Quantcast
Channel: The Official Scripting Guys Forum! forum
Viewing all articles
Browse latest Browse all 15028

Renaming a User Account Does Not Automatically Change the Profile Path

$
0
0

Hello guys,

When you rename a user account in on a computer that is running Windows 7, the user profile path is not changed automatically. It may cause some confusion when the %SystemDrive%\users folder is viewed, especially when some software use this path.

Because my AD hosts about one thousand users and computers, and because users can log on several computers.

I want to create a script which compare in a csv file that I own (SId, samaccountname) and the list of profile you can see by exploring "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList" of each computer.

Then, the idea is to rename the property :ProfileImagePath and of course the user folder with the name (c:\users\test; c:\users\renametest : for example).

Did anybody do that ? 

Thank you for help, guys

PATMOY


BOAT


Viewing all articles
Browse latest Browse all 15028

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>