Advertisement
Guest User

Untitled

a guest
Dec 7th, 2019
93
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.80 KB | None | 0 0
  1. Taskkill.exe /F /IM "OneDrive.exe"
  2. Taskkill.exe /F /IM "Explorer.exe"`
  3. if (Test-Path "C:\Windows\System32\OneDriveSetup.exe") { Start-Process "C:\Windows\System32\OneDriveSetup.exe" -ArgumentList "/uninstall" -Wait }
  4. if (Test-Path "C:\Windows\SysWOW64\OneDriveSetup.exe") { Start-Process "C:\Windows\SysWOW64\OneDriveSetup.exe" -ArgumentList "/uninstall" -Wait }
  5. Remove-Item -Path "C:\Windows\ServiceProfiles\LocalService\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\OneDrive.lnk" -Force
  6. Remove-Item -Path "C:\Windows\ServiceProfiles\NetworkService\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\OneDrive.lnk" -Force
  7. reg load HKLM\Temp C:\users\default\ntuser.dat
  8. reg delete HKLM\Temp\SOFTWARE\Microsoft\Windows\CurrentVersion\Run /v OneDriveSetup /f
  9. reg Unload HKLM\Temp
  10. explorer
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement