Reputation: 16
Hi I want to automate the process of selecting some lines from "Personal Communications iSeries Access for Windows". https://i.sstatic.net/doshI.jpg Manually this can be accomplished by:- 1. selecting from mouse (Drag mouse holding LEFT mouse button) 2. Position the cursor and press SHIFT+ARROW keys(UP/DOWN/LEFT/RIGHT).
I tried to do it with VBScript in following way:-
Set WshShell = WScript.CreateObject("WScript.Shell")
WshShell.SendKeys "{RIGHT 5}" 'Position the cursor
WshShell.SendKeys "+{RIGHT 5}" 'Sending SHIFT+Right Arrow five times
But the code for shift+RIGHT Arrow Keys is not working for me. It is writing 66666. Similarly for WshShell.SendKeys "+{LEFT 5}"
I am getting 44444 as output.
These VBScript sendkeys commands are working fine for other windows applications(like MS Word, Notepad).
Any idea how to proceed?
Upvotes: 0
Views: 3487
Reputation: 11
Try turning NumLock on, then use the arrow keys on the numbers 4 and 6.
Upvotes: 1