Jump to content

Recommended Posts

Posted

<SPAN id=boxes>

<IMG

onmouseup=BoxMouseUp()

onmousemove=BoxMouseMove()

onmousedown=BoxMouseDown()

style="Z-INDEX: 3; LEFT: 80px; POSITION: absolute; TOP: 129px" height=1 src="http://10.100.47.2/1pixblue.gif" width=250>

$ew = _IETagNameGetCollection($oIE, "IMG")
For $e in $ew
        
    If ($e.src) = "http://10.100.47.24/1pixblue.gif" Then
        _IEAction($e, "focus")
        
        $iScreenX = _IEPropertyGet($e, "screenx")
        $iScreenY = _IEPropertyGet($e, "screeny")
        $iWidth = _IEPropertyGet($e, "width")
        $iHeight = _IEPropertyGet($e, "height")
        
    ;MouseMove($iScreenX + $iWidth/2, $iScreenY + $iHeight/2)
        MouseMove($iScreenX, $iScreenY)
        
        MouseClickDrag("left",$iScreenX, $iScreenY, $iScreenX+100, $iScreenY+160)
        
        ExitLoop
    EndIf
Next

this script goes to the field of view window and tries to draw a box by click and drag. The mouse finds the coordinates and moves to the specified position but never draws the intended box.

see attached jpg----trying to control the blue box.

how can I accomplish that??

post-34326-1216685212_thumb.jpg

Posted

Yup, i just made it. Open paint and it will draw a box for you. Hope that helps, Clipper34.

WinWaitActive("Paint")
Sleep(3000)
MouseClickDrag("left", 146, 232, 555, 245, 5)
Sleep(1000)
MouseClickDrag("left", 555, 245, 562, 460, 5)
Sleep(500)
MouseClickDrag("left", 562, 460, 147, 436, 5)
Sleep(1000)
MouseClickDrag("left", 149, 435, 147, 234, 5)

Posted

Clipper34,

thanks for all the help. Yes it draws the box just by dragging it once.

I was referencing the wrong TAG, ---> one level down of the proper tag.

  • 1 month later...
Posted (edited)

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...