How to Stop EA on specific days of month?? Please recommendations, Thank you.

 

Hello, 

Fareed Alston here, I need to code an existing EA to close at certain of the day, on days of the month that end with a specific number (e.g. close days ending in 5; 05th, 15th, 25th) and open after time has passed (1 hour) or open  days of the month that end with a specific number (e.g. open days ending in 6; 06th, 16th, 26th). 

Thank you for any advice.

Nam-myoho-renge-kyo is a Buddhist phrase, when repeated aloud, changes negative karma in to positive, learn more at nstmyogyoji.org

 
  1. Fareed Alston: I need to code …

    You haven't stated a problem, you stated a want. Show us your attempt (using the CODE button) and state the nature of your difficulty.
              No free help (2017)

    Or pay someone. Top of every page is the link Freelance.
              Hiring to write script - General - MQL5 programming forum (2018)

    We're not going to code it for you (although it could happen if you are lucky or the problem is interesting).
              No free help (2017)


  2. Fareed Alston: close days ending in 5; 05th, 15th, 25th)  … open days ending in 6; 06th, 16th, 26th)
    if( day() % 5 == 5) CloseAll();
    if( day() % 5 == 6) OpenOrders();
    
              see Migrating from MQL4 to MQL5 - MQL5 Articles § 11 (day)
 

William Roeder, Thank you for this, I am following your advice.

Very mystically, I had a good friend named William "Schroeder."




William Roeder #:
  1. You haven't stated a problem, you stated a want. Show us your attempt (using the CODE button) and state the nature of your difficulty.
              No free help (2017)

    Or pay someone. Top of every page is the link Freelance.
              Hiring to write script - General - MQL5 programming forum (2018)

    We're not going to code it for you (although it could happen if you are lucky or the problem is interesting).
              No free help (2017)


  2.           see Migrating from MQL4 to MQL5 - MQL5 Articles § 11 (day)
Reason: