1. Home
  2. Ofir Notify
  3. Integration with indicators and EAs

Integration with indicators and EAs

Ofir Notify can be used by your own indicators and EA to send signals to Telegram. They just have to create a text file, containing the signal, to the following directory:
MQL4/Files/OfirNotify/(Your trading account Number)/Inbox
You can use the following code in your indicator or EA:

string directory="OfirNotify/"+IntegerToString(AccountInfoInteger(ACCOUNT_LOGIN))+"/Inbox";
string filename="Test.txt";
string signal="BUY EURUSD 1.20202 SL=1.201 TP=1.203";
saveStringFile(signal,directory+"/"+filename);
bool saveStringFile(string s,string fileName)
  {
   int handle=FileOpen(fileName,FILE_WRITE|FILE_TXT);
   if(handle==INVALID_HANDLE)
      return(false);
   FileWriteString(handle,s);
   FileClose(handle);
   return(true);
  }

*If you can’t modify the source code of your indicator, we have a solution called Ofir Universal EA. Contact us for more information.

*Why not enabling the subscribers of you signals to automatically copy your trades. Have a look on Ofir Synchro. Contact us for more information.

How can we help?