1

I am currently working in VB.Net console application. I am new to the console application, mostly working in windows forms and sql, and I am trying to write some code to make the mouse click at different spots on the screen at specific times. I have searched the web quite a bit but haven't found anything of much use. Can someone point me in the right direction?

6
  • You'll have to first move the cursor and then make it click. Commented Jul 22, 2016 at 14:23
  • @the_lotus So your saying I will need a way to first figure out the coordinates, for example, the first click gives a messagebox displaying coordinates so I know what I need to add to my code? Commented Jul 22, 2016 at 14:24
  • I don't quite understand. To click the mouse at a specific coordinate, you'll need to call a function to move the cursor at the specific x,y coordinate and then call a function to make a mouse click. If you are looking for a way to find the x, y coordinate you are looking for, then that's a different question. Commented Jul 22, 2016 at 14:26
  • Well, I mean it is kind of both. I will need to know the X/Y coordinate I need before the initiate the code but there seems to be a lot of information on how to do that so I will figure that out on my own. The part I cant seem to find much on is the forcing of a click somewhere on the screen. Commented Jul 22, 2016 at 14:32
  • The link I posted tell you how to get the function for GetCursorPos, SetCursorPos, mouse_event Commented Jul 22, 2016 at 14:39

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.