The Registry object provides the ability to delete a registry key; however it will not delete a key if it contains subkeys beneath it. This capability is built into the product; however, it was not made available through the standard interface due to the damage that could be caused by a simple mistake. If this option were available via the Registry object, accidentally selecting the wrong tree to delete and then applying it to all computers could have disastrous results. Through the use of a custom script, you can take advantage of the slRegDelTree() API function. Please, follow the steps below:
Create a custom script and configure it as a Pre or Post Engine script within the manager console.
1. Open the manager and navigate to either the Pre or Post Engine Script object.
2. Create a new element.
3. To create a new script, simply type a filename of your choice. This filename must end with .kix. Once you've typed the filename, press the pencil icon to edit the contents of the script.
4. Add a line to delete the registry key using the following function slRegDelTree( )
Example: $rc=slRegDelTree('HKLM\Software\America Online')
5. Once you're done editing your custom script, press FILE | SAVE and close the script file.
6. Finally, set the appropriate validation logic for your custom script then save and replicate your changes.
© 2025 Quest Software Inc. ALL RIGHTS RESERVED. Terms of Use Privacy Cookie Preference Center