songcser 发表于 2013-12-5 14:16:11

QTP点击WinObject时的鼠标位置

在QTP进行录制时,点击对象是WinObject,在后面有坐标,是什么坐标,相对坐标吗?有什么用处呢。如Window("Femap with NX Nastran").WinObject("Model").Click 47,12
47和12是什么,为什么有的有,有的没有。谢谢。

Shawn_xiao 发表于 2013-12-10 13:55:07

object.Click , ,

X: Optional. An Integer value. The x-coordinate of the click. Note that the specified coordinates are relative to the upper left corner of the object.Default = micNoCoordinate (-9999) -- center of the object.

Y: Optional. An Integer value. The y-coordinate of the click. Note that the specified coordinates are relative to the upper left corner of the object.Default = micNoCoordinate (-9999) -- center of the object.


Tip: You can enter micNoCoordinate (-9999) for the x and y argument values if you want to enter a value for the button argument without specifying x- and y- coordinates for the click. micNoCoordinate indicates the center of the object.

BUTTON: Optional. A predefined constant or number. See the Constants table, below. The mouse button used to click the object. Default = micLeftBtn (0).

nan2222cy 发表于 2013-12-10 16:54:36

相对吧

janexujing 发表于 2013-12-12 14:51:58

自动化测试技术领航 这本书中介绍过。不过我记不得了。呵呵
页: [1]
查看完整版本: QTP点击WinObject时的鼠标位置