zerosama

New Member
Joined
Jun 15, 2023
Messages
5
Hello,

I bought a new laptop and I am trying to change the location of windows key + E.

Until now I used a method with script.reg with launch.vbs :

Script.reg:

Code:
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\SOFTWARE\Classes\CLSID\{52205fd8-5dfb-447d-801a-d0b52f2e83e1}\Shell\opennewwindow\command]

"DelegateExecute"=""

@="wscript.exe \"C:\\Users\\NAME\\Documents\\launch.vbs\""

Launch.vbs:

Code:
WScript.CreateObject("Wscript.Shell").Run "C:\Users\NAME\Downloads"

I copy as path the launch.vbs file:

"C:\Users\NAME\Documents\launch.vbs"

But I always get the attached error.

What can I do? Thanks.

LE: I switched NAME with my actual pc name for privacy reasons.
 


Attachments

  • 2024-04-12 14_29_25-Windows Script Host.webp
    2024-04-12 14_29_25-Windows Script Host.webp
    10.5 KB · Views: 0
Solution
To change the default location that opens when you press Windows Key + E, the method you're using with a registry script and a VBScript file is generally correct. However, it appears there's an error that's preventing it from executing properly. Let's go through the steps again to ensure everything is set up correctly and troubleshoot any potential issues:

Step-by-Step Instructions​

  1. Adjust the Registry Script and VBScript: Make sure both the .reg file and the .vbs file are correctly formatted and point to the right locations. Replace NAME with your actual user account name.

    Registry Script (script.reg):​

    INI:
    Windows Registry Editor Version 5.00...
To change the default location that opens when you press Windows Key + E, the method you're using with a registry script and a VBScript file is generally correct. However, it appears there's an error that's preventing it from executing properly. Let's go through the steps again to ensure everything is set up correctly and troubleshoot any potential issues:

Step-by-Step Instructions​

  1. Adjust the Registry Script and VBScript: Make sure both the .reg file and the .vbs file are correctly formatted and point to the right locations. Replace NAME with your actual user account name.

    Registry Script (script.reg):​

    INI:
    Windows Registry Editor Version 5.00 [HKEY_CURRENT_USER\SOFTWARE\Classes\CLSID\{52205fd8-5dfb-447d-801a-d0b52f2e83e1}\Shell\opennewwindow\command] "DelegateExecute"="" @="wscript.exe \"C:\\Users\\YourActualUserName\\Documents\\launch.vbs\""

    VBScript (launch.vbs):​

    Code:
    WScript.CreateObject("Wscript.Shell").Run "C:\Users\YourActualUserName\Downloads"
  2. Apply the Registry Changes:
    • Save and close the script.reg file.
    • Double-click script.reg to add the changes to the Windows Registry. You should get a prompt asking if you want to add the information to the registry. Confirm this action.
    []Ensure Script Works Standalone:
    • Before tied to a keystroke, make sure launch.vbs works by double-clicking it manually. It should open the Downloads folder.
    [
    ]Correct Any Errors in VBS File Execution: If double-clicking the VBScript file (launch.vbs) results in an error, ensure the VBScript syntax and file paths are correct.

    Common Issues and Solutions:​

    []Check File Paths:
    • Ensure that the file paths do not contain any errors, such as incorrect directories or typos.
    [
    ]Permissions:
    • Ensure you have the necessary permissions to execute scripts and modify the Windows Registry.
    • Run the script.reg file as an administrator.
    []Escape Characters:
    • Paths in registry entries that include backslashes must use double backslashes (e.g., C:\\Users\\YourActualUserName\\Documents\\launch.vbs).
    [
    ]Verify Registry Key:
    • Confirm that the registry key {52205fd8-5dfb-447d-801a-d0b52f2e83e1} has been correctly modified in the registry.

      Debugging the Error:​

    []View Error Details:
    • If you encounter an error, take note of the exact message. This detail can be critical in determining the cause.
    [
    ]Script Debugging:
    • Run the VBScript in Command Prompt to see real-time error messages:
      Code:
      cmd cscript.exe "C:\Users\YourActualUserName\Documents\launch.vbs"

      Example Completed Files:​

      script.reg:​

      INI:
      Windows Registry Editor Version 5.00 [HKEY_CURRENT_USER\SOFTWARE\Classes\CLSID\{52205fd8-5dfb-447d-801a-d0b52f2e83e1}\Shell\opennewwindow\command] "DelegateExecute"="" @="wscript.exe \"C:\\Users\\YourActualUserName\\Documents\\launch.vbs\""

      launch.vbs:​

      Code:
      WScript.CreateObject("WScript.Shell").Run "C:\Users\YourActualUserName\Downloads"

      Additional Tips:​

    []Backup Registry:
    • Always back up the registry before making changes to avoid potential system issues.
    [
    ]User Account Folder:
    • Triple-check the user account folder name (YourActualUserName) for any discrepancies. By following these steps and ensuring all paths and permissions are correctly set, you should be able to successfully reassign the action of Windows Key + E to open a different directory. If the issue persists, please provide the specific error message you are encountering for a more detailed diagnosis.
 


Solution
Back
Top