SweetPea Posted August 11, 2006 Share Posted August 11, 2006 I am attempting to read the selected line from the GUI of another software.$handle returns the correct info as verified with Au3info.info() is another function that simply writes to my log file for debugging purposes.Selected Count = 1 as it shouldSelected Indices = 80 as it should.I am running on an up to date XPpro install.Func Grabinfo() info("Start Grabinfo") $handle = ControlGetHandle($AppStr, "", "Sys753") info($handle) info(_GUICtrlListViewGetSelectedCount($handle)) info(_GUICtrlListViewGetSelectedIndices($handle)) $count = _GUICtrlListViewGetItemText($handle,_GUICtrlListViewGetSelectedIndices($handle)) info ($count) . . . . EndFuncAll appears fine and the expected values are written to my log until the line beginning with $count = .This line crashes the app I'm trying to read text from, and info($count) is never written to my log.All the needed libraries are #included, and I am running beta compile.To me, it seems as if I'm using almost a direct copy of the sample script from the _GUICtrlListViewGetItemText help at GetItemText Help Page . However, running my script crashes the application I'm trying to read text from!I'd appreciate any thoughts you may have. I'm stumped. What type of GetItemText behavior can crash the app who's GUI it is reading text from?Thank You. Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted August 11, 2006 Moderators Share Posted August 11, 2006 Are you trying to get the information from your own GUI or an outside application? Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
SweetPea Posted August 11, 2006 Author Share Posted August 11, 2006 An outside application. $handle is correctly identifying the area I need to query (according to Au3info). Link to comment Share on other sites More sharing options...
SweetPea Posted August 12, 2006 Author Share Posted August 12, 2006 Anyone? Don't be afraid to toss wild theories around. I'm willing to explore any theory/possibility. Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted August 12, 2006 Moderators Share Posted August 12, 2006 Anyone?Don't be afraid to toss wild theories around. I'm willing to explore any theory/possibility.Sorry, forgot about this post for a bit... You're looking at the wrong controls if you're trying to interact with an outside application, take a look at ControlListView() in the help file to get some results. Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
SweetPea Posted August 12, 2006 Author Share Posted August 12, 2006 Sorry, forgot about this post for a bit... You're looking at the wrong controls if you're trying to interact with an outside application, take a look at ControlListView() in the help file to get some results.Thanks for pointing me in the right direction, Smoke. I'm curious, though....how could the _GUI functions I used to write values to my log file show the correct results if (as I understand it) _GUI functions are based on Autoit created GUI's only? Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted August 12, 2006 Moderators Share Posted August 12, 2006 Thanks for pointing me in the right direction, Smoke. I'm curious, though....how could the _GUI functions I used to write values to my log file show the correct results if (as I understand it) _GUI functions are based on Autoit created GUI's only?Well I can imagine that some functions will work some what on other applications, but there is going to be a limitation by design obviously as it's being customized for AutoIt specifically, thus the other types of functions work similar but with more functionality and less restrictions as an AutoIt specific one. Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. 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