Search code examples
automationui-automationqtphp-uft

Function keys In UFT


  1. Version : Using HP-UFT Tool 11.53 Build 0382.
  2. Question :Wanted to automate Function key F9 for my script but I am not able to as I do for normal keyboard keys what is method to do so.
  3. Work Done : Try to Record for function key Hitting But no record is create for it.
  4. Scenario : In my application on F9 press one popup would come and I just want to test it using UFT Tool.

Solution

  • You can use sendkeys, if you want to hit any key from keyboard. Try the below code.

    Set oWscript = CreateObject("WScript.Shell")
    oWscript.sendkeys"{F9}"