EA premission to trade, or Indicator only

 
Hello everyone, is it possible to make an EA that only allows trading posable if the correct account number is selected. Otherwise only attached indicators are applied to the EA and any trading code is dismissed.
 
GrumpyDuckMan:
Hello everyone, is it possible to make an EA that only allows trading posable if the correct account number is selected. Otherwise only attached indicators are applied to the EA and any trading code is dismissed.

What is "posable" ?

Yes it's possible. Please do some researches before posting.

 
Alain Verleyen:

What is "posable" ?

Yes it's possible. Please do some researches before posting.

   ChartSetInteger(Chart_ID,CHART_SHOW_GRID,false);
   bool TF=ChartSetSymbolPeriod(chartid,charts,TIMEFRAME);
   if(AccountNumber()!=ALLOWED_ACCOUNT)indictor_only();
   if(AccountNumber()!=ALLOWED_ACCOUNT)
       return;


This seems to work.

 

Hello again,

I have copy and pasted the "MACD.mq4" code to my EA.  The problem now is after I try to run the program. To me it looks like it is about to start, but straight away stops. No critical errors displayed.

Some ideas as to why this would happen?

 

I found a couple of things out, but I was interested in the one https://www.mql5.com/en/forum/138577

Detailed explanation of iCustom
Detailed explanation of iCustom
  • 2012.03.19
  • www.mql5.com
Hello. I am new to coding, and am learning a lot, however I have struck something that I cannot get my head around at the moment...
Reason: