i came here when i was searching on the search engine to find how to move mouse cursor arrow to the precise location on screen and then auto click on it,
then magic is happen when i combine simple Ahk script to make some click on any button on the screen with help of Shell32.DLL that call from any trade software (forex or binary with any platform), here below the Shell32.DLL call on any trade platform to open AHK script for auto click Buy or Sell on automatic trade mode,
below is Shell32.DLL cal from MQL 5 script (can be any trade platform also can do the same)
Code: Select all
//
#import "shell32.dll"
int ShellExecuteW(int hWnd, string Verb, string File, string Parameter, string Path, int ShowCmd);// DLL call to open AHK script cross platform
#import
bool r_Higher_Button;
bool r_Lower_Button;
string terminalDataPath = ""+TerminalInfoString(TERMINAL_DATA_PATH)+"\\MQL5\\Files\\AHK_SCRIPT_File_Location\\"; // Folder that AHK script is placed
//
if (.........==.........) {// Any signaling to make a trade decision
r_Higher_Button = ShellExecuteW(0,"Open","Higher_Button.exe",NULL,terminalDataPath,5); }// to make auto click on any buy trade button on any screen position
if (.........==.........) {// Any signaling to make a trade decision
r_Lower_Button = ShellExecuteW(0,"Open","Lower_Button.exe",NULL,terminalDataPath,5); }// to make auto click on any buy trade button on any screen position
Higher_Button.exe
Code: Select all
CoordMode, Mouse, Screen
Click, 173, 110
Sleep 200
Return
Lower_Button.exe
Code: Select all
CoordMode, Mouse, Screen
Click, 28, 108
Sleep 200
Return