EssDee Posted January 30, 2008 Share Posted January 30, 2008 Hi Is it possible to get text from a specified position (area) on the screen? I don't want to copy the position and get it as a picture, I need the text to put it in a text-file. /EssDee Link to comment Share on other sites More sharing options...
martin Posted January 30, 2008 Share Posted January 30, 2008 HiIs it possible to get text from a specified position (area) on the screen? I don't want to copy the position and get it as a picture, I need the text to put it in a text-file./EssDeeControlGetText might do the job. 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. Link to comment Share on other sites More sharing options...
EssDee Posted January 30, 2008 Author Share Posted January 30, 2008 I can't see how. Any example?? Link to comment Share on other sites More sharing options...
BrettF Posted January 30, 2008 Share Posted January 30, 2008 (edited) Something like: #include <WinAPI.au3> $active = WinGetHandle ("[ACTIVE]") $window = WinGetPos ($active) $mouse = MouseGetPos () $tpoint = DllStructCreate("int X;int Y") DllStructSetData ($tpoint, "X", $mouse[0]) DllStructSetData ($tpoint, "Y", $mouse[1]) _WinAPI_ScreenToClient ($active, $tpoint) $x = DllStructGetData($tpoint, "x") $y = DllStructGetData($tpoint, "Y") _WinAPI_EnumWindowsInit() _WinAPI_EnumWindowsChild($active, True) For $i = 1 to $winapi_gaWinList[0][0] $ctrl = ControlGetPos ($active, "", $winapi_gaWinList[$i][0]) If $ctrl[0] >= $x AND $ctrl[0] <= ($x + $ctrl[2]) Then If $ctrl[1] >= $y AND $ctrl[1] <= $y + $ctrl[3] Then MsgBox (0, "", "EUREKA!") EndIf EndIf Next EDIT: May, may not work. Just threw it together... Edited January 30, 2008 by Bert Vist my blog!UDFs: Opens The Default Mail Client | _LoginBox | Convert Reg to AU3 | BASS.au3 (BASS.dll) (Includes various BASS Libraries) | MultiLang.au3 (Multi-Language GUIs!)Example Scripts: Computer Info Telnet Server | "Secure" HTTP Server (Based on Manadar's Server)Software: AAMP- Advanced AutoIt Media Player | WorldCam | AYTU - Youtube Uploader Tutorials: Learning to Script with AutoIt V3Projects (Hardware + AutoIt): ArduinoUseful Links: AutoIt 1-2-3 | The AutoIt Downloads Section: | SciTE4AutoIt3 Full Version! Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now