Windows 11 Tweaks, Fixes and Modifications [Overview]

Discussion in 'Windows 11' started by Enthousiast, Jul 1, 2021.

  1. Xtreme21

    Xtreme21 MDL Addicted

    Jun 21, 2021
    690
    1,093
    30
    #261 Xtreme21, Aug 2, 2021
    Last edited: Aug 2, 2021
    No mate, that's how I have it set (left). Actually I'll redo the screenshot as default, centred, should have done so really. Cheers.

    Fixed screenshot.
     
  2. hannubys

    hannubys MDL Novice

    Jun 21, 2007
    35
    4
    0
    I used this reg tweak on Windows 10 to add "Run as administrator" for any powershell script file but this doesn't work anymore on windows 11. Do you know how to add it in context menu ? Microsoft add it by default for any batch file (bat, cmd) but not for PS1.

    ;// Add Run as Administrator context menu
    [HKEY_CLASSES_ROOT\Microsoft.PowerShellScript.1\Shell\runas]
    "HasLUAShield"=""

    [HKEY_CLASSES_ROOT\Microsoft.PowerShellScript.1\Shell\runas\command]
    @="powershell.exe \"-Command\" \"if((Get-ExecutionPolicy ) -ne 'AllSigned') { Set-ExecutionPolicy -Scope Process Bypass }; & '%1'\""
     
  3. SunLion

    SunLion MDL Senior Member

    May 11, 2011
    318
    373
    10
    Try this one:
     

    Attached Files:

  4. hannubys

    hannubys MDL Novice

    Jun 21, 2007
    35
    4
    0
    Thank but this one is not exactly what I need. I need to execute existing powershell file as admin, not open powershell windows as admin.
     
  5. Xtreme21

    Xtreme21 MDL Addicted

    Jun 21, 2021
    690
    1,093
    30
    Disable (Not Remove) Windows 11 Startup Sound

    Code:
    Windows Registry Editor Version 5.00
    
    [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\EditionOverrides]
    "UserSetting_DisableStartupSound"=dword:00000001
    Credit others, found on web.
     
  6. AveYo

    AveYo MDL Expert

    Feb 10, 2009
    1,836
    5,693
    60
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  7. d5aqoëp

    d5aqoëp MDL Addicted

    Jan 19, 2017
    788
    578
    30
    Is there any reg tweak to enable dark mode by default on fresh installation OOBE ?

    Code:
    Windows Registry Editor Version 5.00
    
    [HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Themes\Personalize]
    "AppsUseLightTheme"=dword:00000000
    
    [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Themes\Personalize]
    "AppsUseLightTheme"=dword:00000000
    
    This tweak when integrated doesn't activate dark mode by default. But once booted into Windows, it can fully change into dark mode without any issues. Is there any setup flag perhaps?
     
  8. jsmith242

    jsmith242 MDL Novice

    Feb 7, 2014
    30
    46
    0
    You likely need to load NTUSER.DAT under C:\Users\Default and make the change there instead of HKCU
     
  9. d5aqoëp

    d5aqoëp MDL Addicted

    Jan 19, 2017
    788
    578
    30
    How to do that?
     
  10. KleineZiege

    KleineZiege MDL Expert

    Dec 11, 2018
    1,683
    1,929
    60
    must this regkey be in boot.wim or install.wim ?
    Code:
    [HKEY_LOCAL_MACHINE\SYSTEM\Setup\MoSetup]
    "AllowUpgradesWithUnsupportedTPMOrCPU"=dword:00000001
     
  11. abbodi1406

    abbodi1406 MDL KB0000001

    Feb 19, 2011
    16,197
    84,762
    340
    I guess boot.wim index 1 or current OS, or both
     
  12. KleineZiege

    KleineZiege MDL Expert

    Dec 11, 2018
    1,683
    1,929
    60
    then rather boot.wim index 2, I guess.
    I do it like this, I put it in boot.wim index 1 + 2 and in the install.wim
    Then I am on the safe side I think
     
  13. KleineZiege

    KleineZiege MDL Expert

    Dec 11, 2018
    1,683
    1,929
    60
    #276 KleineZiege, Aug 12, 2021
    Last edited: Aug 12, 2021
    @drew84

    in your script Win11 ISO Modifier (Bypassing MS Requirements) v.1.2.2

    according to the cmd script there is the Murphy78_Apply-Image-Script
    is copied into the index 2 of boot.wim, it always says 0 files copied, I also checked, no files are copied.
    Is this what is wanted ?
    Code:
    @echo off & color 17
    Set Ver=: 1.2.2  2021-07-09 :
    title Win11 ISO Modifier %Ver% by MyDigitallife Member ^(a modification by W0LF aka. drew84^)
    SetLocal EnableDelayedExpansion
    echo *****************************************************************
    echo ------------------- Ensure Admin Privileges ---------------------
    echo *****************************************************************
    
    REM  --> Check for permissions 
    >nul 2>&1 "%SYSTEMROOT%\system32\cacls.exe" "%SYSTEMROOT%\system32\config\system" 
    REM --> If error flag set, we do not have admin. 
    if '%errorlevel%' NEQ '0' (    echo Requesting administrative privileges...    goto UACPrompt) else ( goto gotAdmin ) 
    :UACPrompt 
    echo Set UAC = CreateObject^("Shell.Application"^) > "%temp%\getadmin.vbs" 
    echo UAC.ShellExecute "%~s0", "", "", "runas", 1 >> "%temp%\getadmin.vbs" 
    "%temp%\getadmin.vbs" 
    exit /B
    :gotAdmin
    echo:                  Got Administrator Privilege
    
    echo *****************************************************************
    echo.
    echo *****************************************************************
    echo *        Win11 ISO Modifier Script %Ver%  *
    echo *            (c) 2021 by Mydigitallife Member            *
    echo *****************************************************************
    
    Powershell -Command "Write-Output '    : Welcome To Windows 11 ISO Modifier Project by MyDigitallife Member : ' '' ':***********************************************************************:' '' '                                                  { Urgent }' '' '                                Please Disable Your Antivirus ' '' '                              Please Use WIM Based ISO Only' '' '                          Please Dont Use Already Serviced ISO ' '' '                 This Project Works Only on Win10 64Bit Host OS ' '' ':***********************************************************************:' '' 'You Can Close this Script Now and Re Execute After Urgent Notice Done' '' '                       Waiting Time is 10 Min Until You Press OK' | MSG "%username%" /TIME:600 /W"
    
    echo  Win11 ISO Modifier Script %Ver% Creating Modified Win11 to Bypass SB TPM Requirements Started at %DATE% %TIME%
    
    echo *****************************************************************
    echo.
    echo *****************************************************************
    echo --- Extract ISO to Script Path and Create Mount Directory
    echo *****************************************************************
    
    cd /d "%~dp0"
    IF NOT EXIST "DVD" md "DVD"
    IF NOT EXIST "Mount" md "Mount"
    IF NOT EXIST "MountRE" md "MountRE"
    IF NOT EXIST "MountBoot" md "MountBoot"
    Bin\7z.exe x -y -o"DVD" "ISO\*.iso"
    
    echo *****************************************************************
    echo.
    echo *****************************************************************
    echo --- Export Single WIM Index of Your Choice to Script Path
    echo *****************************************************************
    
    SET /A count=0
    FOR /F "tokens=2 delims=: " %%i IN ('DISM /Get-WimInfo /WimFile:"DVD\sources\install.wim" ^| findstr "Index"') DO SET images=%%i
    FOR /L %%i in (1, 1, %images%) DO CALL :CountIndex %%i
    echo. Wim Image contains the following %images% indexes :
    echo.
    FOR /L %%i in (1, 1, %images%) DO (
    echo.  [%%i] !name%%i!
    )
    GOTO ExportIndex
    
    echo *****************************************************************
    
    :MOVE
    echo *****************************************************************
    echo --- Move Back Exported WIM Image to its Source Path
    echo *****************************************************************
    
    move /y "install.wim" "DVD\sources\install.wim"
    
    echo *****************************************************************
    echo.
    echo *****************************************************************
    echo --- Mount WIM Images to Mount Directory
    echo *****************************************************************
    
    echo --- Mount Install Wim
    Powershell -Command "Mount-WindowsImage -ImagePath 'DVD\sources\install.wim' -Index 1 -Path 'Mount' -Verbose"
    echo *****************************************************************
    echo --- Mount Boot Wim 1st Index
    Powershell -Command "Mount-WindowsImage -ImagePath 'DVD\sources\boot.wim' -Index 1 -Path 'MountBoot' -Verbose"
    echo *****************************************************************
    echo --- Bypass TPM 2.0 SecureBoot Ram ^& Storage Checks Boot Wim Index 1
    reg load "HKLM\OfflineSYSTEM" "MountBoot\Windows\System32\config\SYSTEM"
    
    reg add "HKLM\OfflineSYSTEM\Setup\LabConfig" /v "BypassTPMCheck" /t REG_DWORD /d 1 /f
    reg add "HKLM\OfflineSYSTEM\Setup\LabConfig" /v "BypassSecureBootCheck" /t REG_DWORD /d 1 /f
    reg add "HKLM\OfflineSYSTEM\Setup\LabConfig" /v "BypassRAMCheck" /t REG_DWORD /d 1 /f
    reg add "HKLM\OfflineSYSTEM\Setup\LabConfig" /v "BypassStorageCheck" /t REG_DWORD /d 1 /f
    reg add "HKLM\OfflineSYSTEM\Setup\MoSetup" /v "AllowUpgradesWithUnsupportedTPMOrCPU" /t REG_DWORD /d 1 /f
    reg unload "HKLM\OfflineSYSTEM"
    echo *****************************************************************
    echo --- Enable Insider ^'Beta' Channel Requirements Boot Wim Index 1
    reg load "HKLM\OfflineSOFTWARE" "MountBoot\Windows\System32\config\SOFTWARE"
    
    reg add "HKLM\OfflineSOFTWARE\Microsoft\WindowsSelfHost\Applicability" /v "BranchName" /t REG_SZ /d "Beta" /f
    reg add "HKLM\OfflineSOFTWARE\Microsoft\WindowsSelfHost\Applicability" /v "Ring" /t REG_SZ /d "External" /f
    reg add "HKLM\OfflineSOFTWARE\Microsoft\WindowsSelfHost\Applicability" /v "ContentType" /t REG_SZ /d "Mainline" /f
    
    reg add "HKLM\OfflineSOFTWARE\Microsoft\WindowsSelfHost\UI\Selection" /v "UIBranch" /t REG_SZ /d "Beta" /f
    reg add "HKLM\OfflineSOFTWARE\Microsoft\WindowsSelfHost\UI\Selection" /v "UIRing" /t REG_SZ /d "External" /f
    reg add "HKLM\OfflineSOFTWARE\Microsoft\WindowsSelfHost\UI\Selection" /v "UIContentType" /t REG_SZ /d "Mainline" /f
    reg unload "HKLM\OfflineSOFTWARE"
    echo *****************************************************************
    echo --- Save ^& Unmount boot Wim Index 1
    Powershell -Command "Dismount-WindowsImage -Path 'MountBoot' -Save -CheckIntegrity -Verbose"
    echo *****************************************************************
    echo --- Mount Boot Wim 2nd Index
    Powershell -Command "Mount-WindowsImage -ImagePath 'DVD\sources\boot.wim' -Index 2 -Path 'MountBoot' -Verbose"
    echo *****************************************************************
    echo --- Bypass TPM 2.0 SecureBoot Ram ^& Storage Checks Boot Wim Index 2
    reg load "HKLM\OfflineSYSTEM" "MountBoot\Windows\System32\config\SYSTEM"
    
    reg add "HKLM\OfflineSYSTEM\Setup\LabConfig" /v "BypassTPMCheck" /t REG_DWORD /d 1 /f
    reg add "HKLM\OfflineSYSTEM\Setup\LabConfig" /v "BypassSecureBootCheck" /t REG_DWORD /d 1 /f
    reg add "HKLM\OfflineSYSTEM\Setup\LabConfig" /v "BypassRAMCheck" /t REG_DWORD /d 1 /f
    reg add "HKLM\OfflineSYSTEM\Setup\LabConfig" /v "BypassStorageCheck" /t REG_DWORD /d 1 /f
    reg add "HKLM\OfflineSYSTEM\Setup\MoSetup" /v "AllowUpgradesWithUnsupportedTPMOrCPU" /t REG_DWORD /d 1 /f
    
    reg unload "HKLM\OfflineSYSTEM"
    echo *****************************************************************
    echo --- Enable Insider ^'Beta^' Channel Requirements Boot Wim Index 2
    reg load "HKLM\OfflineSOFTWARE" "MountBoot\Windows\System32\config\SOFTWARE"
    
    reg add "HKLM\OfflineSOFTWARE\Microsoft\WindowsSelfHost\Applicability" /v "BranchName" /t REG_SZ /d "Beta" /f
    reg add "HKLM\OfflineSOFTWARE\Microsoft\WindowsSelfHost\Applicability" /v "Ring" /t REG_SZ /d "External" /f
    reg add "HKLM\OfflineSOFTWARE\Microsoft\WindowsSelfHost\Applicability" /v "ContentType" /t REG_SZ /d "Mainline" /f
    
    reg add "HKLM\OfflineSOFTWARE\Microsoft\WindowsSelfHost\UI\Selection" /v "UIBranch" /t REG_SZ /d "Beta" /f
    reg add "HKLM\OfflineSOFTWARE\Microsoft\WindowsSelfHost\UI\Selection" /v "UIRing" /t REG_SZ /d "External" /f
    reg add "HKLM\OfflineSOFTWARE\Microsoft\WindowsSelfHost\UI\Selection" /v "UIContentType" /t REG_SZ /d "Mainline" /f
    reg unload "HKLM\OfflineSOFTWARE"
    echo *****************************************************************
    echo --- Copy Apply Image Script to Boot Wim Index 2
    XCOPY "Murphy78_Apply-Image-Script\" "MountBoot\" /E /I /Q /Y
    echo *****************************************************************
    echo --- Save ^& Unmount boot Wim Index 2
    Powershell -Command "Dismount-WindowsImage -Path 'MountBoot' -Save -CheckIntegrity -Verbose"
    echo *****************************************************************
    echo --- Export Boot Wim All Index to Compress Maximum
    Dism /Export-Image /SourceImageFile:"DVD\sources\boot.wim" /ALL /DestinationImageFile:"boot.wim" /Compress:max /CheckIntegrity
    echo *****************************************************************
    echo --- Moving Boot Wim Back to its Source Directory
    move /y "boot.wim" "DVD\sources\boot.wim"
    echo *****************************************************************
    echo --- Mount WinRE Wim
    Powershell -Command "Mount-WindowsImage -ImagePath 'Mount\Windows\System32\Recovery\Winre.wim' -Index 1 -Path 'MountRE' -Verbose"
    echo *****************************************************************
    echo --- Bypass TPM 2.0 SecureBoot Ram ^& Storage Checks Boot Wim WinRE Wim
    reg load "HKLM\OfflineSYSTEM" "MountRE\Windows\System32\config\SYSTEM"
    
    reg add "HKLM\OfflineSYSTEM\Setup\LabConfig" /v "BypassTPMCheck" /t REG_DWORD /d 1 /f
    reg add "HKLM\OfflineSYSTEM\Setup\LabConfig" /v "BypassSecureBootCheck" /t REG_DWORD /d 1 /f
    reg add "HKLM\OfflineSYSTEM\Setup\LabConfig" /v "BypassRAMCheck" /t REG_DWORD /d 1 /f
    reg add "HKLM\OfflineSYSTEM\Setup\LabConfig" /v "BypassStorageCheck" /t REG_DWORD /d 1 /f
    reg add "HKLM\OfflineSYSTEM\Setup\MoSetup" /v "AllowUpgradesWithUnsupportedTPMOrCPU" /t REG_DWORD /d 1 /f
    
    reg unload "HKLM\OfflineSYSTEM"
    echo *****************************************************************
    echo --- Enable Insider ^'Beta^' Channel Requirements Boot Wim WinRE Wim
    reg load "HKLM\OfflineSOFTWARE" "MountRE\Windows\System32\config\SOFTWARE"
    
    reg add "HKLM\OfflineSOFTWARE\Microsoft\WindowsSelfHost\Applicability" /v "BranchName" /t REG_SZ /d "Beta" /f
    reg add "HKLM\OfflineSOFTWARE\Microsoft\WindowsSelfHost\Applicability" /v "Ring" /t REG_SZ /d "External" /f
    reg add "HKLM\OfflineSOFTWARE\Microsoft\WindowsSelfHost\Applicability" /v "ContentType" /t REG_SZ /d "Mainline" /f
    
    reg add "HKLM\OfflineSOFTWARE\Microsoft\WindowsSelfHost\UI\Selection" /v "UIBranch" /t REG_SZ /d "Beta" /f
    reg add "HKLM\OfflineSOFTWARE\Microsoft\WindowsSelfHost\UI\Selection" /v "UIRing" /t REG_SZ /d "External" /f
    reg add "HKLM\OfflineSOFTWARE\Microsoft\WindowsSelfHost\UI\Selection" /v "UIContentType" /t REG_SZ /d "Mainline" /f
    reg unload "HKLM\OfflineSOFTWARE"
    echo *****************************************************************
    echo --- Save ^& Unmount WinRE Wim
    Powershell -Command "Dismount-WindowsImage -Path 'MountRE' -Save -CheckIntegrity -Verbose"
    echo *****************************************************************
    echo --- Export WinRE Wim to Compress Maximum
    Dism /Export-Image /SourceImageFile:"Mount\Windows\System32\Recovery\Winre.wim" /ALL /DestinationImageFile:"Winre.wim" /Compress:max /CheckIntegrity
    echo *****************************************************************
    echo --- Moving WinRE Wim Back to its Source Directory
    move /y "Winre.wim" "Mount\Windows\System32\Recovery\Winre.wim"
    
    echo *****************************************************************
    echo.
    echo *****************************************************************
    echo.--- Bypass Unsupported Hardware
    echo *****************************************************************
    
    reg load "HKLM\OfflineSYSTEM" "Mount\Windows\System32\config\SYSTEM"
    
    reg add "HKLM\OfflineSYSTEM\Setup\LabConfig" /v "BypassTPMCheck" /t REG_DWORD /d 1 /f
    reg add "HKLM\OfflineSYSTEM\Setup\LabConfig" /v "BypassSecureBootCheck" /t REG_DWORD /d 1 /f
    reg add "HKLM\OfflineSYSTEM\Setup\LabConfig" /v "BypassRAMCheck" /t REG_DWORD /d 1 /f
    reg add "HKLM\OfflineSYSTEM\Setup\LabConfig" /v "BypassStorageCheck" /t REG_DWORD /d 1 /f
    reg add "HKLM\OfflineSYSTEM\Setup\MoSetup" /v "AllowUpgradesWithUnsupportedTPMOrCPU" /t REG_DWORD /d 1 /f
    
    reg unload "HKLM\OfflineSYSTEM"
    echo *****************************************************************
    
    reg load "HKLM\OfflineSOFTWARE" "Mount\Windows\System32\config\SOFTWARE"
    
    reg add "HKLM\OfflineSOFTWARE\Microsoft\WindowsSelfHost\Applicability" /v "BranchName" /t REG_SZ /d "Beta" /f
    reg add "HKLM\OfflineSOFTWARE\Microsoft\WindowsSelfHost\Applicability" /v "Ring" /t REG_SZ /d "External" /f
    reg add "HKLM\OfflineSOFTWARE\Microsoft\WindowsSelfHost\Applicability" /v "ContentType" /t REG_SZ /d "Mainline" /f
    
    reg add "HKLM\OfflineSOFTWARE\Microsoft\WindowsSelfHost\UI\Selection" /v "UIBranch" /t REG_SZ /d "Beta" /f
    reg add "HKLM\OfflineSOFTWARE\Microsoft\WindowsSelfHost\UI\Selection" /v "UIRing" /t REG_SZ /d "External" /f
    reg add "HKLM\OfflineSOFTWARE\Microsoft\WindowsSelfHost\UI\Selection" /v "UIContentType" /t REG_SZ /d "Mainline" /f
    reg unload "HKLM\OfflineSOFTWARE"
    echo *****************************************************************
    echo.
    echo *****************************************************************
    echo --- Backup and Replace 22000 appraiserres.dll with 1703 dll
    echo *****************************************************************
    
    ren "DVD\sources\appraiserres.dll" "appraiserres.dll.bak"
    copy /Y "1703_Appraiserress_DLL\appraiserres.dll" "DVD\Sources"
    
    echo *****************************************************************
    echo.
    echo *****************************************************************
    echo --- Saving and Unmounting Final Modified Win11 Image
    echo *****************************************************************
    
    Powershell -Command "Dismount-WindowsImage -Path 'Mount' -Save -CheckIntegrity -Verbose"
    
    echo *****************************************************************
    echo.
    echo *****************************************************************
    echo --- Export Wim Image Again to Compress Maximum
    echo *****************************************************************
    
    PowerShell -Command "Export-WindowsImage -SourceImagePath 'DVD\sources\install.wim' -SourceIndex 1 -DestinationImagePath 'install.wim' -CompressionType Max -CheckIntegrity -Verbose"
    move /y "install.wim" "DVD\sources\install.wim"
    
    echo *****************************************************************
    echo.
    echo *****************************************************************
    echo --- Create Modified Windows 11 (Bypassing SB TPM Requirements) ISO
    echo *****************************************************************
    
    set /p ISOFileName=Enter ISO Filename :
    "Bin\oscdimg.exe" -bootdata:2#p0,e,b".\DVD\boot\etfsboot.com"#pEF,e,b".\DVD\efi\microsoft\boot\efisys.bin" -o -h -m -u2 -udfver102 -lCPBA_X64FRE_EN-GB_DV9 ".\DVD" "%~dp0%ISOFileName%.iso"
    
    echo *****************************************************************
    echo.
    echo *****************************************************************
    echo --- Remove Extra Files of Project %Ver%
    echo *****************************************************************
    
    cd /d "%~dp0"
    Dism /Cleanup-Mountpoints
    Powershell -Command "Clear-WindowsCorruptMountPoint"
    IF EXIST "DVD" rd /s /q "DVD"
    IF EXIST "Mount" rd /s /q "Mount"
    IF EXIST "MountRE" rd /s /q "MountRE"
    IF EXIST "MountBoot" rd /s /q "MountBoot"
    IF EXIST "SOFTWAREBKP" del /f /q "SOFTWAREBKP"
    
    echo *****************************************************************
    echo Win11 ISO Modifier Script %Ver%  Creation of Modified Win11 to Bypass SB TPM Requirements Completed at %DATE% %TIME%
    echo *****************************************************************
    echo **************************** The End ****************************
    
    Powershell -Command "$wshell=New-Object -ComObject wscript.shell; $wshell.SendKeys('^a')
    Powershell -Command "$wshell=New-Object -ComObject wscript.shell; $wshell.SendKeys('^c')
    Powershell -Command "Get-Clipboard >Tweaker.txt"
    color 02
    pause
    exit /b
    
    :ExportIndex
    echo.
    SET /P INDEXCHOICE=Select Single Image Index Number You Want to Export and Tweak :
    DISM /Export-Image /SourceImageFile:"DVD\sources\install.wim" /Sourceindex:%INDEXCHOICE% /DestinationImageFile:"%~dp0\install.wim" /CheckIntegrity
    echo *****************************************************************
    echo.
    GOTO MOVE
    
    :CountIndex
    SET /A count+=1
    FOR /f "tokens=1* delims=: " %%i IN ('DISM /Get-WimInfo /wimfile:"DVD\sources\install.wim" /index:%1 ^| find /i "Name"') DO SET name%count%=%%j
    
    
    I have tried to modify the script a little bit for the beta channel for me, they would be nice, and could check the script times.

    I also really have to say I don't know if this works as well, I added another regkey in the script

    I must say that I am not familiar with Beta and DEV channels.
     
  14. Xtreme21

    Xtreme21 MDL Addicted

    Jun 21, 2021
    690
    1,093
    30
    So he gets notified that you have tagged him, and alerted of your post, best close the gap between @ and drew84 so it becomes a tag.

    Like this @Xtreme21
     
  15. KleineZiege

    KleineZiege MDL Expert

    Dec 11, 2018
    1,683
    1,929
    60
    script work , updates are coming :)
     
  16. drew84

    drew84 MDL Expert

    Mar 13, 2014
    1,351
    2,308
    60
    ... see this post
     
  17. Enthousiast

    Enthousiast MDL Tester

    Oct 30, 2009
    47,256
    94,677
    450