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

1544Is it possible to click on a button based on button's name in the UI?

Expand Messages
  • kumar21yash
    Oct 6, 2006
    • 0 Attachment
      Hi,
      im trying to click on a button called Go. i could able do this with
      the following code...

      use Win32::GuiTest qw ( :ALL);
      use warnings;

      use strict;
      system "start http://www.Mynewplace.com";
      sleep(1);
      my @mnp = FindWindowLike(undef,'MyNewPlace');

      if (!@mnp)
      {
      die "cann't open the mynewplace page\n";
      }
      else
      {
      printf ("Mynewplace handle control id is %x\n ", $mnp[0]);
      }

      SetForegroundWindow($mnp[0]);

      MouseMoveAbsPix(480,300);
      SendKeys( 'New york');
      SendMouse("{LeftClick}");

      *******is there any other way to click on Go button?

      *******and also after clicking Go button i want my code to wait for
      sometime so that it uploads all the images...etc....

      Thanks...
      yash
    • Show all 6 messages in this topic