|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.ObjectAutoTest.AutoIt
public class AutoIt
Nested Class Summary | |
---|---|
static class |
AutoIt.ByReferenceBoolean
|
static class |
AutoIt.ByReferenceDouble
|
static class |
AutoIt.ByReferenceInteger
|
static class |
AutoIt.ByReferenceLong
|
static class |
AutoIt.ByReferenceString
|
Constructor Summary | |
---|---|
AutoIt()
|
Method Summary | |
---|---|
void |
BlockInput(int nToggle)
Documentation for: BlockInput Will prevent any user input via the mouse or keyboard. |
void |
ClipGet(AutoIt.ByReferenceString szText)
Documentation for: ClipGet Allows you to get text from the clipboard. |
void |
ClipPut(java.lang.String szText)
Documentation for: ClipPut Allows you to get text from the clipboard. |
void |
Close()
Documentation for: Close Closes down AutoIt. |
void |
DetectHiddenText(int nToggle)
Documentation for: DetectHiddenText Some programs use hidden text on windows this can cause problems when trying to script them. |
int |
IfWinActive(java.lang.String szTitle,
java.lang.String szText)
Documentation for: IfWinActive Checks if a given window is currently active. |
int |
IfWinExist(java.lang.String szTitle,
java.lang.String szText)
Documentation for: IfWinExist Checks if a given window current exists (in any state). |
void |
IniDelete(java.lang.String szFile,
java.lang.String szSection,
java.lang.String szValue)
Documentation for: IniDelete Deletes a specified value from a standard .INI file. |
void |
IniRead(java.lang.String szFile,
java.lang.String szSection,
java.lang.String szValue,
AutoIt.ByReferenceString szResult)
Documentation for: IniRead Reads a specified value from a standard .INI file. |
void |
Init()
Documentation for: Init Resets AutoIt to defaults (window delays, key delays, etc.). |
void |
IniWrite(java.lang.String szFile,
java.lang.String szSection,
java.lang.String szValue,
java.lang.String szResult)
Documentation for: IniWrite Write a specified value to a standard .INI file. |
void |
LeftClick(int nX,
int nY)
Documentation for: LeftClick Simulates a mouse left-click at a given coordinate. |
void |
LeftClickDrag(int nX1,
int nY1,
int nX2,
int nY2)
Documentation for: LeftClickDrag Simulates a mouse left-click-drag operation. |
int |
MouseGetPosX()
Documentation for: MouseGetPosX Gets the X coordinate of the mouse pointer. |
int |
MouseGetPosY()
Documentation for: MouseGetPosY Gets the Y coordinate of the mouse pointer. |
void |
MouseMove(int nX,
int nY)
Documentation for: MouseMove Moves the mouse pointer to the specified coordinates. |
void |
RightClick(int nX,
int nY)
Documentation for: RightClick Simulates a mouse right-click at a given coordinate. |
void |
RightClickDrag(int nX1,
int nY1,
int nX2,
int nY2)
Documentation for: RightClickDrag Simulates a mouse right-click-drag operation. |
void |
Send(java.lang.String szLine)
Documentation for: Send Set an error message. |
void |
SetCapslockState(int nToggle)
Documentation for: SetCapslockState This command will correctly set the state of the CAPSLOCK key to either on or off. |
void |
SetKeyDelay(int nDelay)
Documentation for: SetKeyDelay This functions will alter the amount of time that AutoIt pauses between each simulated keypress. |
void |
SetStoreCapslockMode(int nToggle)
Documentation for: SetStoreCapslockMode By default, at the start of a "Send" command AutoIt will store the state of the CAPSLOCK key; at the end of the "Send" command this status will be restored. |
void |
SetTitleMatchMode(int nMode)
Documentation for: SetTitleMatchMode This function will alter the way that AutoIt matches window titles in functions such as WinWait, IfWinActive, etc. |
void |
SetWinDelay(int nDelay)
Documentation for: SetWinDelay This functions will alter the amount of time that AutoIt pauses after performing a WinWait-type function. |
void |
Shutdown(int nFlag)
Documentation for: Shutdown This function can perform various types of shutdown on all Windows operating systems. |
void |
Sleep(int nMilliseconds)
Documentation for: Sleep This function simply pauses for an amount of time. |
void |
WinActivate(java.lang.String szTitle,
java.lang.String szText)
Documentation for: WinActivate This function will activate a specified window. |
void |
WinClose(java.lang.String szTitle,
java.lang.String szText)
Documentation for: WinClose This function will close a specified window |
void |
WinGetActiveTitle(AutoIt.ByReferenceString szTitle)
Documentation for: WinGetActiveTitle A string pointer to receive the window title. |
void |
WinHide(java.lang.String szTitle,
java.lang.String szText)
Documentation for: WinHide This function will hide a specified window. |
void |
WinKill(java.lang.String szTitle,
java.lang.String szText)
Documentation for: WinKill This function will forceably close a specified window. |
void |
WinMaximize(java.lang.String szTitle,
java.lang.String szText)
Documentation for: WinMaximize This function will maximize a specified window. |
void |
WinMinimize(java.lang.String szTitle,
java.lang.String szText)
Documentation for: WinMinimize This function will minimize a specified window. |
void |
WinMinimizeAll()
Documentation for: WinMinimizeAll This function will minimize all windows. |
void |
WinMinimizeAllUndo()
Documentation for: WinMinimizeAllUndo This function will undo a previous WinMinimizeAll call. |
void |
WinMove(java.lang.String szTitle,
java.lang.String szText,
int nX,
int nY,
int nWidth,
int nHeight)
Documentation for: WinMove Use this function to move/resize a specified window. |
void |
WinRestore(java.lang.String szTitle,
java.lang.String szText)
Documentation for: WinRestore This function will restore a window from a minimized state. |
void |
WinSetTitle(java.lang.String szTitle,
java.lang.String szText,
java.lang.String szNewTitle)
Documentation for: WinSetTitle Changes the title of a specified window. |
void |
WinShow(java.lang.String szTitle,
java.lang.String szText)
Documentation for: WinShow This function will show a specified window previously hidden. |
int |
WinWait(java.lang.String szTitle,
java.lang.String szText,
int nTimeout)
Documentation for: WinWait This function will pause until the specified window exists (or the function times out). |
int |
WinWaitActive(java.lang.String szTitle,
java.lang.String szText,
int nTimeout)
Documentation for: WinWaitActive This function will pause until the specified window is active (or the function times out). |
int |
WinWaitClose(java.lang.String szTitle,
java.lang.String szText,
int nTimeout)
Documentation for: WinWaitClose This function will pause until the specified window doesn't exist (or the function times out). |
int |
WinWaitNotActive(java.lang.String szTitle,
java.lang.String szText,
int nTimeout)
Documentation for: WinWaitNotActive This function will pause until the specified window is not active (or the function times out). |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public AutoIt()
Method Detail |
---|
public void Close()
public void Init()
public void Shutdown(int nFlag)
nFlag
- A combination of the flags given in the remarks section.public void Sleep(int nMilliseconds)
nMilliseconds
- The amount of time to sleep in milliseconds. (Note: 1000 milliseconds = 1 second)public void BlockInput(int nToggle)
nToggle
- This should be set to 1 to block input, and 0 to enable input.public void LeftClick(int nX, int nY)
nX
- X coordinate.nY
- Y coordinate.public void LeftClickDrag(int nX1, int nY1, int nX2, int nY2)
nX1
- X1 coordinate (from coordinate).nY1
- Y1 coordinate (from coordinate).nX2
- X2 coordinate (to coordinate).nY2
- Y2 coordinate (to coordinate).public void MouseMove(int nX, int nY)
nY
- Y coordinate.public int MouseGetPosX()
public int MouseGetPosY()
public void RightClick(int nX, int nY)
nX
- X coordinate.nY
- Y coordinate.public void RightClickDrag(int nX1, int nY1, int nX2, int nY2)
nX1
- X1 coordinate (from coordinate).nY1
- Y1 coordinate (from coordinate).nX2
- X2 coordinate (to coordinate).nY2
- Y2 coordinate (to coordinate).public void Send(java.lang.String szLine)
szLine
- A string pointer to the set of keystrokes to send.public void SetCapslockState(int nToggle)
nToggle
- This should be set to 1 to set capslock to ON, and 0 to set capslock to OFF.public void SetKeyDelay(int nDelay)
nDelay
- This functions will alter the amount of time that AutoIt pauses between each simulated keypress.public void SetStoreCapslockMode(int nToggle)
nToggle
- This should be set to 1 to store/restore the capslock at the start/end of a send command, and 0 to ignore capslock state. (Default is 1).public void DetectHiddenText(int nToggle)
nToggle
- This should be set to 1 to enable hidden text detection, and 0 to disable. (Default is 0)public int IfWinActive(java.lang.String szTitle, java.lang.String szText)
szTitle
- A string pointer to the title of the window to match.szText
- A string pointer to the text of the window to match.public int IfWinExist(java.lang.String szTitle, java.lang.String szText)
szTitle
- A string pointer to the title of the window to match.szText
- A string pointer to the text of the window to match.public void SetTitleMatchMode(int nMode)
mode 1: In the szTitle string you specify the start of a window title to match. i.e. for the notepad.exe window (Untitled - Notepad), valid matches would be: Untitled", "Untitled -", "Unt" and "Untitled - Notepad".
mode 2: In the szTitle string you can specify ANY substring of the window title you want to match. Again for the notepad.exe window valid matches would be: Untitled", "Untitled - Notepad", "Notepad", "No".
nMode
- The mode of title matching to use -- see the remarks. Valid modes are 1 and 2. (Default is 1).public void SetWinDelay(int nDelay)
nDelay
- The value in milliseconds pause after a WinWait-related function. (Default 500ms).public void WinActivate(java.lang.String szTitle, java.lang.String szText)
szTitle
- A string pointer to the title of the window to match.szText
- A string pointer to the text of the window to match.public void WinClose(java.lang.String szTitle, java.lang.String szText)
szTitle
- A string pointer to the title of the window to match.szText
- A string pointer to the text of the window to match.public void WinGetActiveTitle(AutoIt.ByReferenceString szTitle)
szTitle
- A string pointer to receive the window title.public void WinHide(java.lang.String szTitle, java.lang.String szText)
szTitle
- A string pointer to the title of the window to match.szText
- A string pointer to the text of the window to match.public void WinKill(java.lang.String szTitle, java.lang.String szText)
szTitle
- A string pointer to the title of the window to match.szText
- A string pointer to the text of the window to match.public void WinMaximize(java.lang.String szTitle, java.lang.String szText)
szTitle
- A string pointer to the title of the window to match.szText
- A string pointer to the text of the window to match.public void WinMinimize(java.lang.String szTitle, java.lang.String szText)
szTitle
- A string pointer to the title of the window to match.szText
- A string pointer to the text of the window to match.public void WinMinimizeAll()
public void WinMinimizeAllUndo()
public void WinMove(java.lang.String szTitle, java.lang.String szText, int nX, int nY, int nWidth, int nHeight)
szTitle
- A string pointer to the title of the window to match.szText
- A string pointer to the text of the window to match.nX
- X coordinate.nY
- Y coordinate.nWidth
- New width of the window (use -1 to leave the size alone)nHeight
- New height of the window (use -1 to leave the size alone)public void WinRestore(java.lang.String szTitle, java.lang.String szText)
szTitle
- A string pointer to the title of the window to match.szText
- A string pointer to the text of the window to match.public void WinSetTitle(java.lang.String szTitle, java.lang.String szText, java.lang.String szNewTitle)
szTitle
- A string pointer to the title of the window to match.szText
- A string pointer to the text of the window to match.szNewTitle
- A string pointer to the text of the new window title.public void WinShow(java.lang.String szTitle, java.lang.String szText)
szTitle
- A string pointer to the title of the window to match.szText
- A string pointer to the text of the window to match.public int WinWait(java.lang.String szTitle, java.lang.String szText, int nTimeout)
szTitle
- A string pointer to the title of the window to match.szText
- A string pointer to the text of the window to match.nTimeout
- Specifies the number of seconds to wait for. Use the value 0 to wait indefinitely.public int WinWaitActive(java.lang.String szTitle, java.lang.String szText, int nTimeout)
szTitle
- A string pointer to the title of the window to match.szText
- A string pointer to the text of the window to match.nTimeout
- Specifies the number of seconds to wait for. Use the value 0 to wait indefinitely.public int WinWaitNotActive(java.lang.String szTitle, java.lang.String szText, int nTimeout)
szTitle
- A string pointer to the title of the window to match.szText
- A string pointer to the text of the window to match.nTimeout
- Specifies the number of seconds to wait for. Use the value 0 to wait indefinitely.public int WinWaitClose(java.lang.String szTitle, java.lang.String szText, int nTimeout)
szTitle
- A string pointer to the title of the window to match.szText
- A string pointer to the text of the window to match.nTimeout
- Specifies the number of seconds to wait for. Use the value 0 to wait indefinitely.public void IniDelete(java.lang.String szFile, java.lang.String szSection, java.lang.String szValue)
An INI file is taken to be a file of the following format:
[SectionName] Value=ResultThe full path of the INI file must be given, however, it is acceptable to use something similar to ".\myfile.ini" to indicate a file in the current working directory. See also IniRead, IniWrite
szFile
- A string pointer to the filename of the .INI file.szSection
- A string pointer to the required section of the .INI file.szValue
- A string pointer to the value to delete.public void IniRead(java.lang.String szFile, java.lang.String szSection, java.lang.String szValue, AutoIt.ByReferenceString szResult)
szFile
- A string pointer to the filename of the .INI file.szSection
- A string pointer to the required section of the .INI file.szValue
- A string pointer to the value to read.szResult
- A string pointer to receive the result.public void IniWrite(java.lang.String szFile, java.lang.String szSection, java.lang.String szValue, java.lang.String szResult)
An INI file is taken to be a file of the following format:
[SectionName] Value=ResultThe full path of the INI file must be given, however, it is acceptable to use something similar to ".\myfile.ini" to indicate a file in the current working directory.
szFile
- A string pointer to the filename of the .INI file.szSection
- A string pointer to the required section of the .INI file.szValue
- A string pointer to the value to read.szResult
- A string pointer to result to write.public void ClipGet(AutoIt.ByReferenceString szText)
szText
- A pointer to a string buffer that will receive the text from the clipboard.public void ClipPut(java.lang.String szText)
szText
- A pointer to a string buffer that contains the text you want to send.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |