Lakes Posted April 6, 2006 Share Posted April 6, 2006 I have done most of what I wanted to with this, the last step is to control the slection of animations.Program URL http://www.digitalpeers.com/This gets the number of items correctly, but does not select any of the items, because I can`t get Focus to the Selection window...;Title: Select Animation ;Class: #32770 ;More ;Control ID: 1018 ;ClassNameNN: Button7 ;Text: Show &Banner ;Control ID: 1083 ;ClassNameNN: SysTreeView321 ;This is a text list ;Control ID: 1062 ;ClassNameNN: SysListView321 ;This show pictures of the available animations. $Title = "Select Animation" $ItemsNo = ControlListView ($Title,"","SysListView321","GetItemCount") DIM $Items[$ItemsNo+1] For $i = 1 to $ItemsNo ;ControlFocus(($Title,"","SysListView321") <<-----------------------causes an error ControlListView ($Title,"","SysListView321","Select", $i) MsgBox(64,"Item Selected ", $i &" Selected") nextHeres a screenshot of the window I am trying to control.Thanks for your help as always. 2015 - Still no flying cars, instead blankets with sleeves. Link to comment Share on other sites More sharing options...
Lakes Posted April 7, 2006 Author Share Posted April 7, 2006 This works to get Focus.. $Title = "Select Animation" $hwList = WinList() For $i=1 To $hwList[0][0] ; MsgBox(0, "Details", "Title=" & $hwList[$i][0] & @LF & "Handle=" & $hwList[$i][1]) If $hwList[$i][0] = $Title then $SelAnim = $hwList[$i][1] EndIf next But still can`t access the SysListView directly, will have to try sending Tabs.. ControlFocus($SelAnim, "", "SysListView321") ControlListView ($SelAnim,"","SysListView321","Select", 1, 0);<<---- causes an error MsgBox(64,"Item Selected ", $i &" Selected") ControlClick($SelAnim, "", "Button1"); <<---- Works 2015 - Still no flying cars, instead blankets with sleeves. Link to comment Share on other sites More sharing options...
Lakes Posted April 8, 2006 Author Share Posted April 8, 2006 The Saga continues... While 1 ;ControlFocus($SelAnim, "", "SysListView321") ControlSend ($SelAnim,"","SysTreeView321","{DOWN}"); <---- Works ;Sleep(2000) ;ControlFocus($SelAnim, "", "SysListView321") ControlSend ($SelAnim,"","SysListView321","{DOWN}") Sleep(2000) WEndI can now select items in the Select Animations Window with the above.But, there is no way to access the button that activates the "Select Animations" in the main panel, (see screenshot).No Control ID, no ClassName, Nothing! So, anyone know how to access the arrow button?Btw, the mouse pointer changes to a pointing hand when its over the button, maybe its acting like a link in a webpage??Thanks! 2015 - Still no flying cars, instead blankets with sleeves. Link to comment Share on other sites More sharing options...
Valuater Posted April 8, 2006 Share Posted April 8, 2006 No Control ID, no ClassName, Nothing! crying.gifyou can try sending "Tabs" till it gets there... then send enter... just an idea8) Link to comment Share on other sites More sharing options...
Lakes Posted April 8, 2006 Author Share Posted April 8, 2006 you can try sending "Tabs" till it gets there... then send enter... just an idea8)Sending keystrokes to the Main panel does`nt work, all the other "buttons" that are pictures/icons have a check box with them, so I can control them with the check boxes.The arrow button that activates the "More Animations" has a hidden checkbox but its not used, you haveto click on the this "button" to get to the More Animations" window.I could maybe get the position of the panel and move the mouse to that control, but thats a sloppy way of doing it. Now, if I could do a control click at X,Y position without having the mouse pointer move... 2015 - Still no flying cars, instead blankets with sleeves. Link to comment Share on other sites More sharing options...
Valuater Posted April 8, 2006 Share Posted April 8, 2006 I have been hoping for a Control Click x,y for a long time also... maybe some day 8) Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted April 8, 2006 Moderators Share Posted April 8, 2006 I have been hoping for a Control Click x,y for a long time also...maybe some day8)We've had it for a while: http://www.autoitscript.com/forum/index.ph...indpost&p=37526 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...
Lakes Posted April 9, 2006 Author Share Posted April 9, 2006 We've had it for a while: http://www.autoitscript.com/forum/index.ph...indpost&p=37526 $WinPos = WinGetPos ($Main) $x = $WinPos[0] $y = $WinPos[1] $W = $WinPos[2] $H = $WinPos[3] ;MsgBox (0, "WinPos", "Window is at X " &$x &"and Y " &$x &" Size is " &$W &" by " &$H) $x = $x + 235 $y = $y + 190 ;MouseMove ($x,$y) ;MouseClick("left",$x,$y) ClickInControl("left",$Main,"","",$x,$y);<<- Only works after button has been pressed once! Only works if the button has already been clicked on... Thought I was on a winner there for a while.. Problem number two Is it possible to get the selected item text from a SysListView321 control? I`ve tried $Sel = ControlGetText ($SelAnim, "", "SysTreeView321") and $Item = ControlListView ($SelAnim,"","SysListView321","GetText", $n1, $n) neither of which works. Thanks for your continued help! 2015 - Still no flying cars, instead blankets with sleeves. 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