Copying file to EVERY profile on a machine.
Posted: 25 Mar 2013 12:29
I think I'm really close but I got stuck and figured I would ask you guys...
I have to copy an updated file to every profile on a machine and every future profile getting created.
I'm certain something is wrong with the for /f statement because running the dir statement alone produces every profile on a machine.
Any ideas?
I have to copy an updated file to every profile on a machine and every future profile getting created.
Code: Select all
for /f "tokens=1,*" %%a in ('dir %systemdrive%\Users' /ad /b) do @xcopy /d /y source "c$\Users\%a\AppData\LocalLow\Sun\Java\Deployment"
I'm certain something is wrong with the for /f statement because running the dir statement alone produces every profile on a machine.
Any ideas?