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

Using SendMouse/Working with Toolbars

Expand Messages
  • Ken Hommel
    Thanks for creating a great tool! Now, onto the gripes: I am trying to use GuiTest to test an MFC application that includes a Toolbar control. I ve tried to
    Message 1 of 1 , Oct 2, 2002
    • 0 Attachment
      Thanks for creating a great tool! Now, onto the gripes:

      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
    Your message has been successfully submitted and would be delivered to recipients shortly.