Tuesday 24 April 2012

Right Clicking Objects Using Device Replay



The function DeviceReplay object to perform a right-click operation on any object by retrieving the coordinates of the object.

Sub RightClickObj(Obj, Offset_x, Offset_y)
       x_coord = Obj.GetROProperty("abs_x")
       y_coord = Obj.GetROProperty("abs_y")
       Set dr = CreateObject("Mercury.DeviceReplay")
       dr.MouseClick x_coord + Offset_x, y_coord + Offset_y, 2
End Sub

No comments:

Post a Comment