We had an issue where user after OS upgrade, the office 365 won’t be getting activated. After couple hours of researched i found this useful article from MS technet which shows how to clean all office settings and registries from an older version of the Office.
We can use this script in two ways
- Run it from command as elevated account, by using “cscript.exe”
example: cscripte.exe “scriptename.vbs“ - add the script on Task sequence using the Run a command step, but first create a package using that script and add that package into this step and add the following lines.
cmd.exe /c cscript.exe “scriptName.vbs“
copy the entire script and paste into notepad and save it as “OlicenseCleanup.vbs”.
Full Source link : View Article