ieuagn321980hr
New Member
- Joined
- Feb 9, 2014
- Messages
- 1
- Thread Author
- #1
Hello guys!
I'm wondering about a script I made after the installation of my Windows 7 x64 ISO is done. The script (bat) contains this:
How should I implant this script after the Win7 installation is done. Tried with SetupComplete (see spolier):
Problem is, I cant use GPO either because I do prefer Home Premium. Many thanks guys and love yaaaa
I'm wondering about a script I made after the installation of my Windows 7 x64 ISO is done. The script (bat) contains this:
@echo off
cd C:\Users\
RD /S /Q "C:\Users\Public\"
cd C:\Users\Unknown\
ATTRIB +H "C:\Users\Unknown\Desktop"
RD /S /Q "C:\Users\Unknown\Searches"
RD /S /Q "C:\Users\Unknown\Saved Games"
RD /S /Q "C:\Users\Unknown\Videos"
RD /S /Q "C:\Users\Unknown\Links"
RD /S /Q "C:\Users\Unknown\Favorites"
RD /S /Q "C:\Users\Unknown\Contacts"
cd C:\
RD /S /Q "C:\PerfLogs\"
RD /S /Q "C:\Program Files\Uninstall Information"
RD /S /Q "C:\Program Files\Windows Media Player"
ATTRIB +H "C:\Program Files\Common Files" /S /D
ATTRIB +H "C:\Program Files\DVD Maker" /S /D
ATTRIB +H "C:\Program Files\Internet Explorer" /S /D
ATTRIB +H "C:\Program Files\MSBuild" /S /D
ATTRIB +H "C:\Program Files\Reference Assemblies" /S /D
ATTRIB +H "C:\Program Files\Windows Defender" /S /D
ATTRIB +H "C:\Program Files\Windows Mail" /S /D
ATTRIB +H "C:\Program Files\Windows NT" /S /D
ATTRIB +H "C:\Program Files\Windows Photo Viewer" /S /D
cd C:\Program Files (x86)\
RD /S /Q "C:\Program Files (x86)\Uninstall Information"
ATTRIB +H "C:\Program Files (x86)\Common Files" /S /D
ATTRIB +H "C:\Program Files (x86)\Internet Explorer" /S /D
ATTRIB +H "C:\Program Files (x86)\MSBuild" /S /D
ATTRIB +H "C:\Program Files (x86)\Reference Assemblies" /S /D
ATTRIB +H "C:\Program Files (x86)\Windows Defender" /S /D
ATTRIB +H "C:\Program Files (x86)\Windows Mail" /S /D
ATTRIB +H "C:\Program Files (x86)\Windows NT" /S /D
ATTRIB +H "C:\Program Files (x86)\Windows Photo Viewer" /S /D
cd C:\ProgramData\Microsoft\Windows\Start Menu\
RD /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Startup"
RD /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Maintenance"
RD /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Games"
RD /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Windows PowerShell"
RD /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\System Tools"
RD /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Accessibility"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Default Programs.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Windows Update.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Sync Center.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Sound Recorder.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Remote Desktop Connection.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Paint.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\displayswitch.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Calculator.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Welcome Center.lnk"
cd C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\
RD /S /Q "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup\"
RD /S /Q "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Maintenance\"
RD /S /Q "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Administrative Tools\"
RD /S /Q "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Accessories\Accessibility"
RD /S /Q "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Accessories\System Tools"
DEL /F /S /Q /A "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Accessories\Windows Explorer.lnk"
DEL /F /S /Q /A "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Accessories\Run.lnk"
DEL /F /S /Q /A "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Accessories\Command Prompt.lnk"
C:\Windows\
RD /S /Q "C:\Windows\Downloaded Program Files"
RD /S /Q "C:\Windows\LiveKernelReports"
RD /S /Q "C:\Windows\Logs"
RD /S /Q "C:\Windows\ModemLogs"
RD /S /Q "C:\Windows\Offline Web Pages"
RD /S /Q "C:\Windows\Temp"
RD /S /Q "C:\Windows\WinToolkit"
cd C:\ProgramData\Microsoft\User Account Pictures\
REN "C:\ProgramData\Microsoft\User Account Pictures\user.bmp" "user.x"
REN "C:\ProgramData\Microsoft\User Account Pictures\guest.bmp" "guest.x"
cd C:\Users\
RD /S /Q "C:\Users\Public\"
cd C:\Users\Unknown\
ATTRIB +H "C:\Users\Unknown\Desktop"
RD /S /Q "C:\Users\Unknown\Searches"
RD /S /Q "C:\Users\Unknown\Saved Games"
RD /S /Q "C:\Users\Unknown\Videos"
RD /S /Q "C:\Users\Unknown\Links"
RD /S /Q "C:\Users\Unknown\Favorites"
RD /S /Q "C:\Users\Unknown\Contacts"
cd C:\
RD /S /Q "C:\PerfLogs\"
RD /S /Q "C:\Program Files\Uninstall Information"
RD /S /Q "C:\Program Files\Windows Media Player"
ATTRIB +H "C:\Program Files\Common Files" /S /D
ATTRIB +H "C:\Program Files\DVD Maker" /S /D
ATTRIB +H "C:\Program Files\Internet Explorer" /S /D
ATTRIB +H "C:\Program Files\MSBuild" /S /D
ATTRIB +H "C:\Program Files\Reference Assemblies" /S /D
ATTRIB +H "C:\Program Files\Windows Defender" /S /D
ATTRIB +H "C:\Program Files\Windows Mail" /S /D
ATTRIB +H "C:\Program Files\Windows NT" /S /D
ATTRIB +H "C:\Program Files\Windows Photo Viewer" /S /D
cd C:\Program Files (x86)\
RD /S /Q "C:\Program Files (x86)\Uninstall Information"
ATTRIB +H "C:\Program Files (x86)\Common Files" /S /D
ATTRIB +H "C:\Program Files (x86)\Internet Explorer" /S /D
ATTRIB +H "C:\Program Files (x86)\MSBuild" /S /D
ATTRIB +H "C:\Program Files (x86)\Reference Assemblies" /S /D
ATTRIB +H "C:\Program Files (x86)\Windows Defender" /S /D
ATTRIB +H "C:\Program Files (x86)\Windows Mail" /S /D
ATTRIB +H "C:\Program Files (x86)\Windows NT" /S /D
ATTRIB +H "C:\Program Files (x86)\Windows Photo Viewer" /S /D
cd C:\ProgramData\Microsoft\Windows\Start Menu\
RD /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Startup"
RD /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Maintenance"
RD /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Games"
RD /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Windows PowerShell"
RD /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\System Tools"
RD /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Accessibility"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Default Programs.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Windows Update.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Sync Center.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Sound Recorder.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Remote Desktop Connection.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Paint.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\displayswitch.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Calculator.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Welcome Center.lnk"
cd C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\
RD /S /Q "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup\"
RD /S /Q "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Maintenance\"
RD /S /Q "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Administrative Tools\"
RD /S /Q "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Accessories\Accessibility"
RD /S /Q "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Accessories\System Tools"
DEL /F /S /Q /A "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Accessories\Windows Explorer.lnk"
DEL /F /S /Q /A "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Accessories\Run.lnk"
DEL /F /S /Q /A "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Accessories\Command Prompt.lnk"
C:\Windows\
RD /S /Q "C:\Windows\Downloaded Program Files"
RD /S /Q "C:\Windows\LiveKernelReports"
RD /S /Q "C:\Windows\Logs"
RD /S /Q "C:\Windows\ModemLogs"
RD /S /Q "C:\Windows\Offline Web Pages"
RD /S /Q "C:\Windows\Temp"
RD /S /Q "C:\Windows\WinToolkit"
cd C:\ProgramData\Microsoft\User Account Pictures\
REN "C:\ProgramData\Microsoft\User Account Pictures\user.bmp" "user.x"
REN "C:\ProgramData\Microsoft\User Account Pictures\guest.bmp" "guest.x"
How should I implant this script after the Win7 installation is done. Tried with SetupComplete (see spolier):
\sources\$OEM$\$$\Setup\Scripts
@echo OFF
cd %~dp0
attrib -R -A -S -H *.*
SHUTDOWN /R /T 5
RMDIR /S /Q "%WINDIR%\Setup\Scripts"
@echo off
cd C:\Users\
RD /S /Q "C:\Users\Public\"
cd C:\Users\Unknown\
ATTRIB +H "C:\Users\Unknown\Desktop"
RD /S /Q "C:\Users\Unknown\Searches"
RD /S /Q "C:\Users\Unknown\Saved Games"
RD /S /Q "C:\Users\Unknown\Videos"
RD /S /Q "C:\Users\Unknown\Links"
RD /S /Q "C:\Users\Unknown\Favorites"
RD /S /Q "C:\Users\Unknown\Contacts"
cd C:\
RD /S /Q "C:\PerfLogs\"
RD /S /Q "C:\Program Files\Uninstall Information"
RD /S /Q "C:\Program Files\Windows Media Player"
ATTRIB +H "C:\Program Files\Common Files" /S /D
ATTRIB +H "C:\Program Files\DVD Maker" /S /D
ATTRIB +H "C:\Program Files\Internet Explorer" /S /D
ATTRIB +H "C:\Program Files\MSBuild" /S /D
ATTRIB +H "C:\Program Files\Reference Assemblies" /S /D
ATTRIB +H "C:\Program Files\Windows Defender" /S /D
ATTRIB +H "C:\Program Files\Windows Mail" /S /D
ATTRIB +H "C:\Program Files\Windows NT" /S /D
ATTRIB +H "C:\Program Files\Windows Photo Viewer" /S /D
cd C:\Program Files (x86)\
RD /S /Q "C:\Program Files (x86)\Uninstall Information"
ATTRIB +H "C:\Program Files (x86)\Common Files" /S /D
ATTRIB +H "C:\Program Files (x86)\Internet Explorer" /S /D
ATTRIB +H "C:\Program Files (x86)\MSBuild" /S /D
ATTRIB +H "C:\Program Files (x86)\Reference Assemblies" /S /D
ATTRIB +H "C:\Program Files (x86)\Windows Defender" /S /D
ATTRIB +H "C:\Program Files (x86)\Windows Mail" /S /D
ATTRIB +H "C:\Program Files (x86)\Windows NT" /S /D
ATTRIB +H "C:\Program Files (x86)\Windows Photo Viewer" /S /D
cd C:\ProgramData\Microsoft\Windows\Start Menu\
RD /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Startup"
RD /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Maintenance"
RD /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Games"
RD /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Windows PowerShell"
RD /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\System Tools"
RD /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Accessibility"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Default Programs.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Windows Update.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Sync Center.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Sound Recorder.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Remote Desktop Connection.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Paint.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\displayswitch.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Calculator.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Welcome Center.lnk"
cd C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\
RD /S /Q "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup\"
RD /S /Q "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Maintenance\"
RD /S /Q "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Administrative Tools\"
RD /S /Q "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Accessories\Accessibility"
RD /S /Q "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Accessories\System Tools"
DEL /F /S /Q /A "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Accessories\Windows Explorer.lnk"
DEL /F /S /Q /A "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Accessories\Run.lnk"
DEL /F /S /Q /A "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Accessories\Command Prompt.lnk"
C:\Windows\
RD /S /Q "C:\Windows\Downloaded Program Files"
RD /S /Q "C:\Windows\LiveKernelReports"
RD /S /Q "C:\Windows\Logs"
RD /S /Q "C:\Windows\ModemLogs"
RD /S /Q "C:\Windows\Offline Web Pages"
RD /S /Q "C:\Windows\Temp"
RD /S /Q "C:\Windows\WinToolkit"
cd C:\ProgramData\Microsoft\User Account Pictures\
REN "C:\ProgramData\Microsoft\User Account Pictures\user.bmp" "user.x"
REN "C:\ProgramData\Microsoft\User Account Pictures\guest.bmp" "guest.x"
@echo OFF
cd %~dp0
attrib -R -A -S -H *.*
SHUTDOWN /R /T 5
RMDIR /S /Q "%WINDIR%\Setup\Scripts"
@echo off
cd C:\Users\
RD /S /Q "C:\Users\Public\"
cd C:\Users\Unknown\
ATTRIB +H "C:\Users\Unknown\Desktop"
RD /S /Q "C:\Users\Unknown\Searches"
RD /S /Q "C:\Users\Unknown\Saved Games"
RD /S /Q "C:\Users\Unknown\Videos"
RD /S /Q "C:\Users\Unknown\Links"
RD /S /Q "C:\Users\Unknown\Favorites"
RD /S /Q "C:\Users\Unknown\Contacts"
cd C:\
RD /S /Q "C:\PerfLogs\"
RD /S /Q "C:\Program Files\Uninstall Information"
RD /S /Q "C:\Program Files\Windows Media Player"
ATTRIB +H "C:\Program Files\Common Files" /S /D
ATTRIB +H "C:\Program Files\DVD Maker" /S /D
ATTRIB +H "C:\Program Files\Internet Explorer" /S /D
ATTRIB +H "C:\Program Files\MSBuild" /S /D
ATTRIB +H "C:\Program Files\Reference Assemblies" /S /D
ATTRIB +H "C:\Program Files\Windows Defender" /S /D
ATTRIB +H "C:\Program Files\Windows Mail" /S /D
ATTRIB +H "C:\Program Files\Windows NT" /S /D
ATTRIB +H "C:\Program Files\Windows Photo Viewer" /S /D
cd C:\Program Files (x86)\
RD /S /Q "C:\Program Files (x86)\Uninstall Information"
ATTRIB +H "C:\Program Files (x86)\Common Files" /S /D
ATTRIB +H "C:\Program Files (x86)\Internet Explorer" /S /D
ATTRIB +H "C:\Program Files (x86)\MSBuild" /S /D
ATTRIB +H "C:\Program Files (x86)\Reference Assemblies" /S /D
ATTRIB +H "C:\Program Files (x86)\Windows Defender" /S /D
ATTRIB +H "C:\Program Files (x86)\Windows Mail" /S /D
ATTRIB +H "C:\Program Files (x86)\Windows NT" /S /D
ATTRIB +H "C:\Program Files (x86)\Windows Photo Viewer" /S /D
cd C:\ProgramData\Microsoft\Windows\Start Menu\
RD /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Startup"
RD /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Maintenance"
RD /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Games"
RD /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Windows PowerShell"
RD /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\System Tools"
RD /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Accessibility"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Default Programs.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Windows Update.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Sync Center.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Sound Recorder.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Remote Desktop Connection.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Paint.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\displayswitch.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Calculator.lnk"
DEL /F /S /Q /A "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories\Welcome Center.lnk"
cd C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\
RD /S /Q "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup\"
RD /S /Q "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Maintenance\"
RD /S /Q "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Administrative Tools\"
RD /S /Q "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Accessories\Accessibility"
RD /S /Q "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Accessories\System Tools"
DEL /F /S /Q /A "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Accessories\Windows Explorer.lnk"
DEL /F /S /Q /A "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Accessories\Run.lnk"
DEL /F /S /Q /A "C:\Users\Unknown\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Accessories\Command Prompt.lnk"
C:\Windows\
RD /S /Q "C:\Windows\Downloaded Program Files"
RD /S /Q "C:\Windows\LiveKernelReports"
RD /S /Q "C:\Windows\Logs"
RD /S /Q "C:\Windows\ModemLogs"
RD /S /Q "C:\Windows\Offline Web Pages"
RD /S /Q "C:\Windows\Temp"
RD /S /Q "C:\Windows\WinToolkit"
cd C:\ProgramData\Microsoft\User Account Pictures\
REN "C:\ProgramData\Microsoft\User Account Pictures\user.bmp" "user.x"
REN "C:\ProgramData\Microsoft\User Account Pictures\guest.bmp" "guest.x"
Problem is, I cant use GPO either because I do prefer Home Premium. Many thanks guys and love yaaaa
- Joined
- Mar 14, 2023
- Messages
- 38,589
It seems like you have a script that is meant to clean up certain directories and perform actions after the installation of Windows 7 x64 ISO is complete. You are trying to figure out how to implement this script effectively. To run a script like this after the Windows installation is complete, you can use a method like the "SetupComplete.cmd" script. This script runs during the final stage of Windows setup after the user has completed the Out-Of-Box Experience (OOBE). Here's how you can proceed:
- Create the SetupComplete.cmd Script:
- Place your cleanup script content in a file named "SetupComplete.cmd."
- Ensure that this script is saved in the correct directory:
%WINDIR%\Setup\Scripts
.
- Content of the SetupComplete.cmd Script:
- In the "SetupComplete.cmd" script, you would include all the commands you want to run after Windows setup completion.
- This script runs with elevated permissions.
- Script Placement:
- Make sure the "SetupComplete.cmd" script is located in the correct directory to run automatically after Windows installation.
- Verify Execution:
- Once Windows setup completes, the script should automatically execute and perform the actions you specified. Here's an example of what your "SetupComplete.cmd" script might look like:
Code:
@echo off cd %~dp0 REM Add your cleanup script contents below this line cd C:\Users\ RD /S /Q "C:\Users\Public\" REM More cleanup actions as needed cd C:\ RD /S /Q "C:\PerfLogs\" REM Add more directory cleanup commands here REM Renaming files cd C:\ProgramData\Microsoft\User Account Pictures\ REN "C:\ProgramData\Microsoft\User Account Pictures\user.bmp" "user.x" REN "C:\ProgramData\Microsoft\User Account Pictures\guest.bmp" "guest.x"
- Once Windows setup completes, the script should automatically execute and perform the actions you specified. Here's an example of what your "SetupComplete.cmd" script might look like: