sendkeys PC Software


Welcome, Guest. Please login or register.
Username:   Password:

Hosted in the Cloud RSS

Recent Topics

Gallery Latest


431 Views
0 comment(s)

414 Views
0 comment(s)


745 Views
0 comment(s)

581 Views
0 comment(s)


462 Views
0 comment(s)

478 Views
1 comment(s)

Search The Gallery

User Info

Welcome, Guest. Please login or register.
May 24, 2017, 10:47:06 AM

Login with username, password and session length

Forum
Web
Gallery
Search:         Keywords:

Pages: [1]

sendkeys

Viewing: 0 Members and 1 Guest       Total Views: 1357

Offline 8pla.net Topic starter
United States WWW Posts: 153
Rank: Apprentice Adept

What I like most about VBScript is: sendkeys.  JavaScript may be more popular, but VBScript is such a powerful beast.  Using the sendkeys syntax, we get to automate the usage of applications, in terms of starting them up and getting them to do things automatically, completely hands off on the keyboard and mouse.
Posted April 15, 2015, 03:10:44 AM Logged
My Very Enormous Monster Just Stopped Using Nine

Online Data
United Kingdom Administrator
Posts: 4601
Rank: Certified

Interesting  Smiley

Here is a little more information on "sendkeys" should anyone like to know.

SendKeys Method

Posted April 15, 2015, 10:31:44 AM Logged

Offline 8pla.net Topic starter
United States WWW Posts: 153
Rank: Apprentice Adept

This code is untested, because I am not on Windows.
So for that reason, it is posted for discussion purposes
only.  But, this is some of what I used to do with sendkeys.

Code:
' Start Notepad
Set WshShell = WScript.CreateObject("WScript.Shell")
WshShell.Run "notepad", 9

' Let it finish loading...
WScript.Sleep 500

' Start typing without touching the keyboard
WshShell.SendKeys "Datahopa is fun!"
WshShell.SendKeys "{ENTER}"
Posted April 20, 2015, 23:17:46 PM Logged
My Very Enormous Monster Just Stopped Using Nine

Offline DaveMorton
United States WWW Global Moderator
Posts: 2498
Rank: Certified
Comfort the Disturbed! Disturb the Comfortable!

I copied the text and pasted into Notepad, saving it on the desktop as dh.vbs - I then ran the script, and it behaved just as intended. Well done, 8-Man! thumbsup
Posted April 21, 2015, 00:26:57 AM Logged
Safe, Reliable Insanity, Since 1961!
Chat With Morti!

CAPTCHA4us

Online Data
United Kingdom Administrator
Posts: 4601
Rank: Certified

Gets my approval  Grin
Posted April 21, 2015, 01:19:53 AM Logged
Pages: [1]
Jump to:  

Site Activity
Most Online Today: 137
36 Guests, 2 Users
Data, Urania