batch file help

Status
Not open for further replies.

benzimm86

In Runtime
Messages
487
I am trying to write a batch file that will delete a registry key because at work our regedit is disabled. So far i am able to get cmd to open and but then it prompts me if im sure i want to delete the reg key. How do i get a y and enter to get filled in automatically? here is what i have so far.

@echo
REG DELETE HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\System /v DisableRegistryTools
exit
 
Pretty sure that you can use the /f switch behind your delete command to force the change rather than prompt for the confirmation.
 
Status
Not open for further replies.
Back
Top Bottom