GET-IT: TEAMS DAY | 1-Day Free Virtual Conference all about Teams. Here on - 8/12/20 GET-IT: TEAMS DAY - 8/12/20

Run as different User on a VBscript + Hide the Password (Solved)

Home Forums Scripting Windows Script Host Run as different User on a VBscript + Hide the Password (Solved)

Viewing 1 post (of 1 total)
  • Author
  • Avatar


    I just want to share this with everyone.

    I would like a user to run a VBscript with different user credentials on their desktop, but NOT knowing the password.

    1.) Convert .VBS file to .EXE file using this freeware tool.…rogramid=26028

    2.) Hide the “Run as different user” password.

    1. Right click on the desktop select New >> Shortcut >> browse to the newly created .exe file >> Next >> Finish.
    2. Right on the custom shortcut select Properties and go to the Target: box and type this in and hit ok …
    runas.exe /savecred /user:domainuser “C:usersbobdesktopvbs.exe” (Of course…put your own directory path where the executable file is located)
    3. When double clicking on the custom shortcut, a command windows will appear and ask for the users’ password. You only have to enter just once. The next time you run the custom shortcut, it will NOT ask for the password.

    The credentials are stored in the “Manage your credentials” under User Account in the Control Panel.

    Hopefully this will help someone like it did for me.

Viewing 1 post (of 1 total)

You must be logged in to reply to this topic.