When you want to Click at a Random Screen Location, you can define a Rectangular Area in which the Mouse Click must be performed. Once you have added a Left Click to the Macro Script, you can edit it’s parameters to enable the Random Screen Location and define a Rectangular Area in which you want the Script to Click.
To get started, do add a Left Click to the Script with the help of Pick Button or with the help of Keyboard Shortcut. Yes you can optionally add a Left Click at any Screen Location as the actual X and Y Screen Co-ordinates will be changed in the next step. The Post Add Macro Action to the Script talks in detail about using the Pick Button and about the Keyboard Shortcut Method to pick Fixed Screen Location and add selected Action to the Macro Script. The given below procedure outlines the steps required to add a Left Click to the Script and then modify it’s parameters to effectively click at a Random Screen Location in Rectangular Area
Once you have configured the Left Click Macro Action in the Script to do Left Mouse Click at a Random Screen Location in the defined Rectangular Area, the Script Editor will display the Bounding Rectangular Co-Ordinates as displayed in the Screenshot below. In case you wish to Modify the Dimensions or Location of Rectangular area, use the Edit Parameters Screen again.
As per above parameters for the Left Mouse Click in the Script, the bounding Rectangle will remain fixed, however the actual Screen Location will be decided at Run Time and will be a Random Location in the bounding Rectangular Area. You can even use Repeat Count to repeat the execution of the Left Click as configured above. Even when the Macro Action is executed multiple times, each time the actual location of Mouse Click will be decided dynamically and will be a Random Screen Location in the bounding Rectangular Area.
The above Screenshot displays a drawing in Microsoft Paintbrush created by a Macro Script configured to Click at Random Screen Location in a Rectangular Area. Note that the Script Repeat Count is set to 500 and the Script was executed a few times. Yes Paintbrush was configured earlier to draw a Line wherever Mouse Click is done. You can even specify Random Time Delay for the Left Click or any other Macro Action in the Script making it a Random Mouse Clicker kind of Script which will Click at Random Screen Location at Random Time Interval.