Tarakesh

MoveMouse to the windows Tabbed Position

4 posts in this topic

Hi,

First of all I would like say infinite thanks to the team involved in designing this great tool.

Here is my problem

1. Press windows button

2. ESC

3. TAB

4. It will take me to the first pinned icon in the taskbar

5. If I I do SHIFT F10 which usually opens context menu like  right click of the mouse.

6. For one of the application I am using it does not support  Shift + F10 context menu rather it listens to only mouse right click event.

7. I do a search in a tree view of my application and the search item is selected or focused

8. For eg

     User1

     User2

     User3
Now if I search for User1 the tab or focus move to User 1 (Red)

     User1

     User2

     User3

If I search for User3 the tab or focus moves to User 3

Now my question is how can I move the mouse automatically go to the focused item on the window. Such that during automation I can issue MoveClick("{RIGHT}") as {SHIFT F10} is not working from the keyboard. It is a java app, unfortunately it is not honoring the right click events from keyboard to open the context

WinMinimizeAll();
Send("^{ESC}")
Sleep(200)
Send("{ESC}")
Send("{TAB}")

the above scripts take the tab to the first pinned icon in the taskbar. Now i want
MouseMove( "move to tab" selection")

Regards,
Tarakesh

Share this post


Link to post
Share on other sites



#2 ·  Posted

I can't help much with the Java app automation (no experience), but I do have a couple of comments to offer.

Instead of sending keystrokes to automate launching the pinned app, it may be more reliable and efficient to simply launch the application.
Look up the Run and ShellExecute functions.

For the right click issue, have you tried using the Menu or App key [Send({APPSKEY})] to see if it produces the proper behavior?  I know Shift+F10 usually does the same thing, but I have seen inconsistencies between some applications.  Might be worth trying, but probably no as robust as other methods to automate Java apps/controls.

Share this post


Link to post
Share on other sites

#3 ·  Posted

I think my example is wrong.

Let me explain in another way. I have already an application open. There is a list of users displaying on the left side panel with a search box above that list.

SearchBox

User1

User2

User3

UserP

UserZ

In the search box using keyboard  tab navigation I can take the cursor into the searchbox and type User2. After search if User2 is found instead of hiding other users and displaying only this, it automatically moves tab or the focus or cursor to the User 3 and highlighted with some color.

If I Shift F10 it should shiw some extra context menu items where I can do ALT D to delete that user.

Unfortunately to simulate right click usng shift f10 is not working rather MouseClick right. But to do that mouse click i should get the position the current tab or cursuor or focus and then move the mouse to that position and do MouseRight click.

Here the position of the highlighted item after search in the list. If hightlight always goes to at particualar coordinates then no problem. But if i search for UserP or UserZ the highlight goes else where where I miss those coordinates

These Old java GWT apps some times do not support context menu using keynavigation like shift f10.

 

Share this post


Link to post
Share on other sites

#4 ·  Posted

you could probably use wingetpos, wingetclientsize, PixelSearch then finally ControlClick if the highlighted user is visible

a part from that you can check the autoit window tool to see if there are any handles you can work with

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

  • Similar Content

    • Fuzy
      By Fuzy
      #include<img/img.au3>
      #include <AutoItConstants.au3>
      Func Skype()
      $coords = imageSearch(0,0,-1,-1,"Skype.PNG")
      MouseMove($coords[0],$coords[1])
      [when it find the skype icon i want it to move from these coordinates, but of insted of moving to an expecific coordinate i want it to move down from these coordinates, (there is multiple images so i cant move to an specific image)] -- Kinda having trouble telling what i want cuz english isnt my first language, sorry about that. ;X
      MouseClick($MOUSE_CLICK_LEFT)
    • dubd83
      By dubd83
      I am trying to click on a tab within an SWT_Window0. The problem is autoit can not see the tab's text and there is no controlid. I have tried using commands to obtain a handle and text with no luck. Any ideas on how to get control of this tab?
    • Tarakesh
      By Tarakesh
      I have a situation where the desktop is designed in java swings. The nodes JTree is not allowing me to do checkbox selection using "spacebar". I am able to navigate through the nodes using up, down arrow and a tab. When I reach to the desire node selection, mouse left click is not working due a flaw a JTree core. However since it is selected, if mouse cursor auto moved to the position of the selection and send a "click"  then it should be solved. Any ideas much appreciated. 
      the problem with having fixed coordinates are the main windows is divided to 2panels where right panel containing this JTree can be expanded or shrink-ed.

    • myspacee
      By myspacee
      Hello,
      need help to remap '<' button and SHIFT+'<'
      I made a little editor that allows to my users to write using proprietary codes.
      In production we have 2 keys/symbols that i want to 'emulate'. So, when is press on my keyboard :
      < = « SHIFT+< = » Try to use help example _IsPressed :
       
      #include <Misc.au3> #include <MsgBoxConstants.au3> Local $hDLL = DllOpen("user32.dll") While 1 If _IsPressed("10", $hDLL) Then ConsoleWrite("_IsPressed - Shift Key was pressed." & @CRLF) ; Wait until key is released. While _IsPressed("10", $hDLL) Sleep(250) WEnd ConsoleWrite("_IsPressed - Shift Key was released." & @CRLF) ElseIf _IsPressed("1B", $hDLL) Then MsgBox($MB_SYSTEMMODAL, "_IsPressed", "Close the application.") ExitLoop EndIf Sleep(250) WEnd DllClose($hDLL) but how manage keys combination ?
      thank you for any help,
      m.
    • Skeletor
      By Skeletor
      Hi Developers,
       
      While trying to find a way to actually style/skin the GUICtrlCreateTabItem, I read the help file and stated:
      My question to you guys is will this be updated? or am I hoping for something that will never come to pass?
      I've seen scripts between 2007 to 2009 allowing the tabs to be modified
      Reason for my question is I'm trying to make my GUI Tabs look more modern.
      Thanks in advance for reading my post.