Jump to content

Mouse click on a button on a web page


saldous
 Share

Recommended Posts

Hi, I have a script that opens a webpage where there is a logon box. My script can complete the email address and password fields on the web page but when I have the script submit the form the webpage comes back to the login page, I think the website doesn't want to allow this to happen.

So to get around it I'm wanting to have my script complete the fields, but instead of submitting the form I want the mouse to go to the login button and click it. Can this be done? The problem is users will have different screen resolutions so I don't think I can give the mouse coordinates, it needs to locate the login button first and then click it, but I don't know how to do this. Any ideas? Thanks. (PS. I also tried using the Send("{ENTER}") but that had the same problem.

Edited by saldous
Link to comment
Share on other sites

I can't think of another way :-(

I'm having a problem with the WinGetPos, I was trying to use this to locate some text on the web page, then from those co-ordinates do the mouse click, but the WinGetPos always returns the same co-ordinates, and they are not locating the text in the web page.

Link to comment
Share on other sites

Screenshot attached. I want to be able to click the "Log On" Button.

My problem seems to be related to what the help file says about the IEFormSubmit function:

For many HTML forms it is not sufficient to use _IEFormSubmit() because there is often custom Javascript tied to an onclick event for its Submit button. In these cases you'll need to simulate a click of the submit button instead of using _IEFormSubmit(). See the example for the "click" action of _IEAction().

post-20839-1172449743_thumb.jpg

Edited by saldous
Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...