Quantcast
Channel: Windows PowerShell forum
Viewing all articles
Browse latest Browse all 21975

Move Users Favorites Folder in Roaming Profile and then Delete?

$
0
0

Hello,

My current scenario is as follows for user accounts:

\\90.244.233.10\userprofile$\User-16 (this is their profile path)

\\90.244.233.10\userprofile$\User-16\Favorites (this is their favorites folder)

I need to take the above favorites folder and move it to their userhome$ folder found here:

\\90.244.233.10\userhome$\%username%\Favorites (these folders already exist) 

Then delete their complete userprofile$ folder.

How can I achieve this using powershell? I think the tricky part for me is going through each folder in userprofile$ and looking for a \Favorites folder and then matching that userprofile$ foldername to %username% since they're the same.

Thank you.


Viewing all articles
Browse latest Browse all 21975

Trending Articles



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