Micro Focus QTP (UFT) Forums
Problem in Input from keyboard:sendkeys - Printable Version

+- Micro Focus QTP (UFT) Forums (https://www.learnqtp.com/forums)
+-- Forum: Micro Focus UFT (earlier known as QTP) (https://www.learnqtp.com/forums/Forum-Micro-Focus-UFT-earlier-known-as-QTP)
+--- Forum: UFT / QTP Beginners (https://www.learnqtp.com/forums/Forum-UFT-QTP-Beginners)
+--- Thread: Problem in Input from keyboard:sendkeys (/Thread-Problem-in-Input-from-keyboard-sendkeys)



Problem in Input from keyboard:sendkeys - Rachna - 04-09-2009

Hi,
I tried using the sendkeysf for one of my scenario":after click of Ctrl F10 on Insert card dialog box ,a new pop-up screen should appear of Key Enter where by other details should be entered.But in my case after executing the below mentioned script..no Key enter pop-up is coming.Please advise asap.
Code:
Set WshShell = CreateObject("WScript.Shell") WshShell.AppActivate "Insertcard"
WshShell.SendKeys "^{F10}"

i tried using this ,but still as in real scenario after press of Ctrl + F10 the next pop up appears of KEY entry...but after executing the script
in this statement:
Code:
WshShell.SendKeys "^{F10}"

no action is seen on the screen.

Please let me know how it can be resolved?
I am using QTP9.2 and working on Java Windows application

Thanks ,
Rachna


RE: Problem in Input from keyboard:sendkeys - anil2u - 10-14-2013

Hi,

I am not sure if java windows support events, but for a browser dialog
i used to use Browser.Page.Dialog.FireEvent "onfocus" before passing the keystrokes and it works for me.
Try that once Smile

Cheers,
Anil