Greetings I am faced with the task of automating the deletion of a section in the registry on a specific condition.
In the HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall section, you need to find the subkey containing the parameter (Name: "DisplayName" , Value: "Example" ) by the script, and delete this subsection.
The whole problem is that the subsection should be searched every time by the script, because it has a name like this: {B99E3435-0B06-210C-B1B8-5954D5ADF936}
|
REG.EXEand unload the specified branch to the stream. Pass the stream toFIND.EXE, leave only the line with the specified values. Pass it toFOR, where to parse into tokens and get the name of the partition. Build a command to delete the partition and runREG.EXE, passing this command to it. - Akina