Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.

# Windows 7: copy .bat from one computer to many computer

 23 Jan 2015 #1 adiariyanto Windows 7 Embedded 2 posts copy .bat from one computer to many computer Hi.. i would like to know if somebody ever done before I need to replace login.bat file that locate in C:\ProgramData\Microsoft\Windows\Start Menu\Programs\StartUp in 96 computer with new login.bat that I have. I already use xcopy and copy command but it need administrator access / password. is there any script / bat file / a way to do this ? all administrator password account is same and I have it. My System Specs
 .
 23 Jan 2015 #2 RolandJS Windows 7 Professional 64-bit 1,633 posts I have to rush off to work, however, you can get from here Take Ownership REG script and/or Run As Administrator REG script. I mean the folks here can tell you where to find, how to activate, how to use those two scripts. My System Specs
 24 Jan 2015 #3 Pyprohly Windows 10, Windows 8.1 Pro, Windows 7 Professional, OS X El Capitan 725 posts Sydney, NSW Hi Adiariyanto, I'm not entirely knowledgeable about networks, but it shouldn't be hard to whip up a file replace batch script. Something like... Code: @echo off for /f "usebackq delims=" %%I in ("C:\networkcomputers.txt") do ( xcopy "\\%COMPUTERNAME%\C$\some\path\to\logon.bat" "\\%%~I\C$\ProgramData\Microsoft\Windows\Start Menu\Programs\Startup" /y ) Should get the job done. With "C:\networkcomputers.txt" being a newline-separated list of all 96 network computers. My System Specs
 .
 26 Jan 2015 #4 adiariyanto Windows 7 Embedded 2 posts Quote: Originally Posted by Pyprohly Hi Adiariyanto, I'm not entirely knowledgeable about networks, but it shouldn't be hard to whip up a file replace batch script. Something like... Code: @echo off for /f "usebackq delims=" %%I in ("C:\networkcomputers.txt") do ( xcopy "\\%COMPUTERNAME%\C$\some\path\to\logon.bat" "\\%%~I\C$\ProgramData\Microsoft\Windows\Start Menu\Programs\Startup" /y ) Should get the job done. With "C:\networkcomputers.txt" being a newline-separated list of all 96 network computers. Hi Pyprohly I try copy your script into notepad and make it .bat file , but it doesnt work ? do I miss something ? I try run your script as administrator, but in target computer the .bat file does not copied.. then I try remove /y and got an error %%I was unexpected at this time.. My System Specs
 26 Jan 2015 #5 Pyprohly Windows 10, Windows 8.1 Pro, Windows 7 Professional, OS X El Capitan 725 posts Sydney, NSW I would like to reiterate, I'm no network guru. But if you'd like to stick around I'd be happy to work with you in finding a solution. Do you have a remote computer you can test with? Get it ready. Verify that you have access to this computer's Startup directory by listing it's contents. Code: dir "\\ComputerName\C$\ProgramData\Microsoft\Windows\Start Menu\Programs\Startup" Substituting "ComputerName" with the name of the computer you decide to perform testing on. If you accomplished the above with success, take matters to the next step and make an attempt to Xcopy some arbitrary file on your local computer to the remote computer's Startup folder with the following, Code: xcopy "C:\Some\random\file\on\your\machine.txt" "\\ComputerName\C$\ProgramData\Microsoft\Windows\Start Menu\Programs\Startup" Again, substituting "ComputerName" accordingly. Post back with your findings. My System Specs