Powered by: Dharamveer Saxena

Saturday, April 2, 2011

How to get clipboard text using VBScript

' Open notepad
Set WshShell = WScript.CreateObject("WScript.Shell")
WshShell.Run "notepad", 9

' Give Notepad time to load
WScript.Sleep 500

' Do The Paste
WshShell.SendKeys "%e"
WshShell.SendKeys "p"

No comments:

Post a Comment