Mouseclick to external program
Posted: 18 Mar 2012, 10:52
First of all my personal compliments for this software.
I started using it with the Buttons - Saitek X52.
In fact when using the Saitek 'Profile' it happens that the mouse-cursor is making unpredictable moves.
Now this problem is resolved using hidmacros.
I have one question regarding the correct us of the "MourseClick" Script.
Example:
- external program "Test Program" with 1 Button
- New Macro "Test"
HIDMacros.MouseClick 2160, 175, 1
On Mouseclick Button is activated.
In this case the Mouse-Cursor is not returning to previous Window.
The Mouse-Move coordinates x, y should be valid only for the program itself. When moving the program on the screen, it does not work anymore.
When referrering to the "Window Title" then it should work indipendently of the program position on the screen.
My Question:
What is the programming code together with the "HIDMacros.Mouseclick...." SPECIFYING/REFERRING to the external
program "Test Program" (Window Title).
Must it be within a complete Sub..end sub or Function ecc...
I have considered your example but something i'm doing wrong using .....AppActivate "Test Program".
"""
Dim wsh
Set wsh = CreateObject("Wscript.Shell")
wsh.AppActivate "Notepad"
"""
Many thanks for your kind help,
regards,
Friedrich
I started using it with the Buttons - Saitek X52.
In fact when using the Saitek 'Profile' it happens that the mouse-cursor is making unpredictable moves.
Now this problem is resolved using hidmacros.
I have one question regarding the correct us of the "MourseClick" Script.
Example:
- external program "Test Program" with 1 Button
- New Macro "Test"
HIDMacros.MouseClick 2160, 175, 1
On Mouseclick Button is activated.
In this case the Mouse-Cursor is not returning to previous Window.
The Mouse-Move coordinates x, y should be valid only for the program itself. When moving the program on the screen, it does not work anymore.
When referrering to the "Window Title" then it should work indipendently of the program position on the screen.
My Question:
What is the programming code together with the "HIDMacros.Mouseclick...." SPECIFYING/REFERRING to the external
program "Test Program" (Window Title).
Must it be within a complete Sub..end sub or Function ecc...
I have considered your example but something i'm doing wrong using .....AppActivate "Test Program".
"""
Dim wsh
Set wsh = CreateObject("Wscript.Shell")
wsh.AppActivate "Notepad"
"""
Many thanks for your kind help,
regards,
Friedrich