VBscript to Send Key Strokes (Auto Response) to the Windows Applications

Here is a very simple and quick VBscript that can automated press OK on your Windows Run prompt. If you have any of the command types in your Run box, that gets executed simply by running this script. set shell = createobject("wscript.shell") wscript.sleep 200 success = shell.appactivate("Run") if success then shell.sendkeys "{tab}" wscript.sleep 400 shell.sendkeys "{enter}"   Steps: Open the Run, (use Windows key + R) Type cmd in the Run box Open the Explorer where you have the above code saved as .vbs script Double click on the .vbs script file for it to run That’s it will see […]

Read more

PS: Using GetEnvironmentVariable to Manage Environment Variables

Here’s a quick tip on working with Windows PowerShell. These are published every week for as long as we can come up with new tips. If you have a tip you’d like us to share or a question about how to do something, let us know. Find more tips in the Windows PowerShell Tip of the Week archive. Creating and Modifying Environment Variables Most people know how easy it is to use Windows PowerShell to retrieve information about environment variables. Want to see all your environment variables and their values? This command should do the trick: Copy Get-ChildItem Env: In […]

Read more

PS: Working with Environment Provider

PROVIDER NAME Environment DRIVES Env: SHORT DESCRIPTION Provides access to the Windows environment variables. DETAILED DESCRIPTION The Windows PowerShell Environment provider lets you get, add, change, clear, and delete Windows environment variables in Windows PowerShell. The Environment provider is a flat namespace that contains only objects that represent the environment variables. The variables have no child items. Each environment variable is an instance of the System.Collections.DictionaryEntry class. The name of the variable is the dictionary key. The value of the environment variable is the dictionary value. The Environment provider exposes its data store in the Env: drive. To work with […]

Read more