Jump to content

Mouse Move and Left Click VBS


Recommended Posts

Basically i want the mouse to move to a certain place on the screen say xxx,xxx then perform a left click in that area

I then will open up a right click context menu by doing shift+F10 and use the arrow keys to make my selection

Does anyone know some code that will move the mouse to a place on the screen and then click the left mouse button.

Thanks guys

Link to comment
Share on other sites


I've been coding in VBS for a few years now and I'm honestly unaware of how you can move the mouse cursor with it. You can send pretty much any sort of keyboard command. You may want to investigate using AutoIt which really shines in that sort of thing. And if you're able to figure out VBscript, you'll have no problems figuring out AutoIt.

Link to comment
Share on other sites

Tryed that autoit couldnt work it out.

I know you can do mouse moves with a macro so unless i just make an exe macro and tell it to run that

So the vb opens another vb that opens a macro that runs and then closes.

Sound good?

Link to comment
Share on other sites

Sound good?

Hey if it works great. Something to keep in mind, and this would hold true with AutoIt as well, is that whenever you try to put the mouse cursor on a set of coordinates you're really asking for trouble. What if the screen resolution is not always the same, does the application always open in the same part of the screen? Ask yourself questions like that. There are indeed times where it seems as though coordinates are your only option. SpywareBlaster is such a circumstance. They obviously programmed that utility with the intention of thwarting such automation. Presumeably in order to sell subscriptions to their autoupdate service.

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
  • Recently Browsing   0 members

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