Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to avoid system lock while running Windows Based Application
#5
Solved: 11 Years, 3 Months, 3 Weeks ago
Create a VBS file, Copy below code and paste it.

Code:
Const micVoid = 0
Const micByte = 26
Const micLong = 3
Const KEYEVENTF_KEYUP = &H2
Set Extern = CreateObject("Mercury.ExternObj")
extern.Declare micVoid, "keybd_event", "user32", "keybd_event", micByte, micbyte, miclong, micLong
Extern.Declare micVoid, "Sleep", "kernel32", "Sleep", micLong
While True
  extern.keybd_event 0, 0, KEYEVENTF_KEYDOWN, 0
  Extern.Sleep 20000
Wend


Save it, and double click on it, it will work
Reply


Messages In This Thread
RE: How to avoid system lock while running Windows Based Application - by Munna.Sarfraz - 01-17-2012, 03:44 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  capturing message on web page when caps lock is on helan 0 2,378 04-29-2015, 05:25 AM
Last Post: helan
  System work slow with UFT 12.02 elyanivson 0 2,765 02-10-2015, 05:09 PM
Last Post: elyanivson
  can not record Windows application QTP 12.1 pratapchinta 1 2,231 12-01-2014, 06:30 PM
Last Post: supputuri
  UFT 12 unable to recognize the objects of a java based application (jre - 1.7.0_65) Sushant Dasgupta 2 9,166 09-17-2014, 03:47 PM
Last Post: Sushant Dasgupta
Cool ntdll.dll crash problem with UFT 11.5 Application in Windows Server 08 gangadhar 1 4,808 06-13-2014, 04:43 PM
Last Post: vinod123

Forum Jump:


Users browsing this thread: 2 Guest(s)