Help with indicator

 

Hello everyone.

I am programming an indicator for Metatrader 4 and I would need the current signal to appear every 5 minutes, that is, at o'clock, at 5 minutes, at 10 minutes, etc.

Following the criteria of the Brazilian MHI strategy, how to program the other values I have no problems since I do it with the eabuilder page, but I still need to add that code that says that every 5 minutes the arrow appears following the parameters that I put in the indicator.

Thanks in advance.

 
menocino:

Hello everyone.

I am programming an indicator for Metatrader 4 and I would need the current signal to appear every 5 minutes, that is, at o'clock, at 5 minutes, at 10 minutes, etc.

Following the criteria of the Brazilian MHI strategy, how to program the other values I have no problems since I do it with the eabuilder page, but I still need to add that code that says that every 5 minutes the arrow appears following the parameters that I put in the indicator.

Thanks in advance.

If you want it to check, say, at 10:00, 10:05, 10:10, etc.

const int minute      = TimeMinute(TimeCurrent());
const int interval    = 5;
const bool isInterval = minute % interval == 0;

if (isInterval) {
  //--- run code here
}
 
menocinosince I do it with the eabuilder page,

EA builder, EA Builder Pro, EATree, Etasoft forex generator, Forex Strategy Builder, ForexEAdvisor STRATEGY BUILDER, ForexRobotAcademy.com, FX EA Builder, fxDreema, Forex Generator, FxPro, Molanis, Octa-FX Meta Editor, Online Forex Expert Advisor Generator, Strategy Builder FX, Strategy Quant, Visual Trader Studio, MQL5 Wizard, etc., are all the same. You will get something quick, but then you will spend a much longer time trying to get it right, than if you learned the language up front, and then just wrote it.

  1. Since you haven't learned MQL4/5, therefor there is no common language for us to communicate.
    If we tell you what you need, you can't code it.
    If we give you the code, you don't know how to integrate it into yours.
    We are willing to HELP you when you post your attempt (using Code button) and state the nature of your problem, but we are not going to debug your hundreds of lines of code. You are essentially going to be on your own.

  2. EA builder makes bad code counting up while closing multiple orders.
    EA builder makes bad code Bars is unreliable (Max bars in chart), volume is unreliable (miss ticks.) Always use time.
    EA builder makes bad code, not adjusting for 4/5 digit brokers, TP/SL and slippage.
    EA builder makes bad code, not adjusting for ECN brokers. pre-Build 500)
    EA builder makes bad code, not checking return codes.

  3. EATree uses objects on chart to save values — not persistent storage (files or GV+Flush.) No recovery (crash/power failure.)

  4. FX EA Builder makes bad code, not checking return codes.
    FX EA Builder makes bad code, loosing open tickets on terminal restart. No recovery (crash/power failure.)
    FX EA Builder makes bad code, not adjusting stops for the spread.
    FX EA Builder makes bad code, using OrdersTotal directly.

  5. FOREXEADVISOR STRATEGY BUILDER makes bad code, non-updateing global variables.
    FOREXEADVISOR STRATEGY BUILDER makes bad code, compilation errors.
    FOREXEADVISOR STRATEGY BUILDER makes bad code, not checking return codes.

Learn to code it, or pay someone (Freelance) someone to code it.
          Hiring to write script - General - MQL5 programming forum #1 (2019)

Reason: