' Below Piece of Snippet will Type in the notepad You can also send special characters such as SHIFT, CTRL, and ALT, which are represented by the plus sign (+), the caret (^), and the percent sign (%), respectively. To send multiple characters (for example, abc), use "abc" as the string argument. To send a single character (for example, x), use "x" as the string argument. The SendKeys method will send keystroke(s) to the active window. WshShell.SendKeys "^f" ' The caret (^) represents the CTRL key. WshShell.AppActivate "Put the label of the browser" ' Activate the browser window Set WshShell = CreateObject("WScript.Shell") ' This code executes the CTRL+F key combination (search) on a browser. Use the SendKeys method to type the key combination. Activate the browser in which you want to execute the keys.ģ. In these cases you can use SendKeys method to send keyboard input to your application.ĭownload and install the Windows Scripting Host.Ģ. These Web/Windows objects do not have a type method associated with them that can be used to replay these keys. There are some Web/Windows objects which will perform actions when certain key commands, such as CTRL+SHIFT+ESC are entered.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. Archives
December 2022
Categories |