Loading ...
Sorry, an error occurred while loading the content.

134Re: SendMouse/Working with Toolbars

Expand Messages
  • mike.derobio@marconi.com
    Oct 3, 2002
    • 0 Attachment

      I can't recall why I didn't use the SendMouse function, but I remember
      having some trouble with it. I used the MouseMoveAbsPix function instead:

      #add item button

      Works great for me. Maybe this will work for you.


      > I am trying to use GuiTest to test an MFC application that includes a
      > Toolbar control. I've tried to use SendMouse( "{ABSx, y}" ) to move
      > the cursor over a button, followed by SendMouse( "{LEFTCLICK}" ) to
      > trigger a button. I get an error message for the first SendMouse
      > command: "GuiTest: Unmatched mouse command!" The second command
      > works, but since the cursor hasn't moved, it doesn't help.
      > The snippet looks like this:
      > # Send a mouse click to the File Open button
      > SendMouse( "{ABS13, 50}" );
      > SendMouse( "{LEFTCLICK}" );
      > Does anyone have any examples of using SendMouse, or testing a
      > Toolbar control?
      > I've also tried PushChildButton, with the window handle for the
      > Toolbar (confirmed the HWND value with Spy++) and the control ID for
      > the button (since Toolbar buttons don't have titles). This also
      > failed, but without any message.
      > Thank you,
      > Ken Hommel
    • Show all 2 messages in this topic