Alright folks, I have managed to Sysprep it twice in a row with the following steps:
1. Open Programs and Features and uninstall all applications (optional)
2. Add the following keys to the Registry:
- HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsStore\WindowsUpdate\AutoDownload, "2", "REG_DWORD"
- HKLM\SOFTWARE\Microsoft\Windows\CloudContent\DisableWindowsConsumerFeatures, "1", "REG_DWORD"
- HKLM\SOFTWARE\Policies\Microsoft\Windows\CloudContent\DisableWindowsConsumerFeatures, "1", "REG_DWORD"
- HKLM\SOFTWARE\Policies\Microsoft\WindowsStore\AutoDownload, "2", "REG_DWORD"
3. Reboot
4. Turn off the Network Adapter
5. Run the following PowerShell commands as Administrator:
- Get-AppxPackage -AllUser | Remove-AppxPackage
- Get-AppxProvisionedPackage -Online | Remove-AppxProvisionedPackage -Online
6. Run the following PowerShell command as Administrator to get the list of left over applications:
- Get-AppxPackage -AllUser | Where PublisherID -eq 8wekyb3d8bbwe | Format-List -Property PackageFullName,PackageUserInformation > c:\list.txt
7. Run the following PowerShell command to clean up any of the "Staged" applications:
- Remove-AppxPackage -Package "PackageFullName"
8. All you should have left are 4 packages:
- Microsoft.AsyncTextService_10.0.17134.1_neutral__8wekyb3d8bbwe
- Microsoft.ECApp_10.0.17134.1_neutral__8wekyb3d8bbwe
- Microsoft.MicrosoftEdgeDevToolsClient_1000.17134.1.0_neutral_neutral_8wekyb3d8bbwe
- Microsoft.MicrosoftEdge_42.17134.1.0_neutral__8wekyb3d8bbwe
9. Go to c:\ProgramData\Microsoft\Windows, right-click on AppRepository and change the security settings, and take ownership of the folder and all items inside, you want to give ownership to ehadmin
10. You need to install SQLiteBrowser3 so you can edit the StateRepository_Machine.srd file in the AppRepository folder (Or use a portable version which is easier)
- Note: Copy the file to c: to make a backup
11. When you open StateRepository_Machine.srd, you need to click Browse Data, then under Table: select Package, and look for those 4 packages under the PackageFullName column, then find what PackageID they are, and take note, in this case: Async is 186, ECApp is 189, MicrosoftEdgeDev is 191, and MicrosoftEdge is 192.
12. Next step is going into the IsInbox column and change the value from a "1" to a "0" for each of those packages
13. Open Command Prompt as Admin, and find the StateRepository task by running the command:
- tasklist /svc /fi "services eq StateRepository"
14. Run the command:
- taskkill -pid PIDNumber /f
This will end the task
15. In SQLiteBrowser3, go to File, Write Changes.
16. Reboot
17. Run PowerShell as admin again and now try to run the command:
- Remove-AppxPackge -Package "PackageFullName" again for the last 4 packages, they should be able to be removed
18. Turn Network Adapter back on
19. Sysprep