Sign in to follow this  
Followers 0
Vectortech

Select Input Box?

2 posts in this topic

I need help modifying a current script that I use. I now have to add a function to click or select a input box. I can't have the script just "enter" through to the box any longer. The box actually has to be clicked on with a mouse click.

#include<array.au3> ;included for _Arraydisplay

#include<excel.au3>

$path = @DesktopDir & '\cyclecount.xls' ;@Desktopdir replaces "C:\Documents and Settings\Purchasing\Desktop"

$oExcel = _ExcelBookOpen($path,0)

$aExcel = _ExcelReadSheetToArray($oExcel)

;_ArrayDisplay($aExcel)

_ExcelBookClose($oExcel)

WinActivate("[CLASS:DEJAWINT]", "")

For $iRow = 1 To $aExcel[0][0] ;$iRow will be incremented untill the last column is reached

ControlSend("[CLASS:DEJAWINT]", "", "", $aExcel[$iRow][1])

ControlSend("[CLASS:DEJAWINT]", "", "", "{Enter}")

ControlSend("[CLASS:DEJAWINT]", "", "", "{1}")

; The next line needs to change to an actual click on the input box now

ControlSend("[CLASS:DEJAWINT]", "", "", "{Enter}")

ControlSend("[CLASS:DEJAWINT]", "", "", $aExcel[$iRow][2])

ControlSend("[CLASS:DEJAWINT]", "", "", "{Enter 4}")

Next

Thanks in advance

Vectortech

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

It's not clear to me what the input box is you want to click, but have you tried ControlClick?

Edited by martin

Serial port communications UDF Includes functions for binary transmission and reception.printing UDF Useful for graphs, forms, labels, reports etc.Add User Call Tips to SciTE for functions in UDFs not included with AutoIt and for your own scripts.Functions with parameters in OnEvent mode and for Hot Keys One function replaces GuiSetOnEvent, GuiCtrlSetOnEvent and HotKeySet.UDF IsConnected2 for notification of status of connected state of many urls or IPs, without slowing the script.

Share this post


Link to post
Share on other sites

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
Sign in to follow this  
Followers 0