How to execute action when I left click my mouse?

Getting started -basics for starting with WinTask

How to execute action when I left click my mouse?

Postby Dowell on Thu Jan 15, 2015 9:54 am

I need my script to execute "some action" whenever I left-click my mouse button. It does not matter where I click. All that matters is that the left-click button was pressed. Is there a way to do that?
Dowell
 
Posts: 19
Joined: Sun Jun 19, 2005 7:02 pm

Re: How to execute action when I left click my mouse?

Postby TechSupport on Fri Jan 16, 2015 10:51 am

Hello,

You need to use OnAction, here is the code:
Code: Select all
Sub launch()
msgbox("left click done")
EndSub

OnAction clickleft
     Button(left,Down)
     DoSub launch
EndAction

Pause 5


Regards.
WinTask Tech Support
TechSupport
 
Posts: 805
Joined: Thu Nov 16, 2006 9:58 am


Return to Getting started

Who is online

Users browsing this forum: No registered users and 1 guest

cron