clicking on 1 specified coördinate
hi all!
i am new on this forum, so i thought, maybe you guys can help me :)
I am from Holland, and not programming vb6 for a long time. But, i like it very much, and learn something new every day :)
But now, i encountered a problem. On e remote computer, i give my program the command to take a screenshot of the whole screen, and put it on an ftp server. Then, i click on a remote program on a certain location of that screenshot, and it sends the coordinates back to the system that made the screenhot.
Lets say i clicked on (400,600), and the screenshot is (1024,768), the size of my screen. Now i want the program that gets the location (400,600) to click on that coordinate of its screen.
Is that possible? and how? i use vb6
many thanx, Dennis Priester
1 Attachment(s)
Re: clicking on 1 specified coördinate
You can use the attached class to move the mouse cursor around and also to click or double click at the current position. The usage is very simple:
VB Code:
Dim mouse As CMouse
Set mouse = New CMouse
mouse.MoveTo 400, 600
mouse.Click ' or Call mouse.Click(vbRightButton) if you want to click with the right button
The coordinates of the MoveTo method must be in pixels.
Re: clicking on 1 specified coördinate
Re: clicking on 1 specified coördinate
ah i see :) so i just have to add your class in the project explorer? many thanx!
Re: clicking on 1 specified coördinate
Yes, you can simply add the class to your project, it will then be compiled together with the rest of your source into the same EXE file. Another option is to add it to an ActiveX DLL project (in which case you must change the Instancing property to 5-MultiUse for the class) and compile it to a DLL which you set a reference to in your main project.
But for this simple class I would just add it to your project directly.