I’m using cmd to run a software installation cycle. The steps are install – uninstall – delete associated folders – install new version.
The installation adds folders in C:Program Files so I need to delete these folders. However, cmd returns “The system cannot find the file specified.”
The code is rmdir C:Program Filesfolder /s /q
. If it’s not in C:Program Files, the folder can be deleted. So I assume something is protecting these folders even though I’m running the cmd as administrator. How to delete folders in program files folder using cmd?