Forum

ENUM_BASE_CORNER corner=CORNER_RIGHT_LOWER has no effect

I am trying desperately to start my arrows from right lower corner, but MQL is insisting on referring all to CORNER_LEFT_UPPER... //+------------------------------------------------------------------+ //| Script program start function |

Are Stop Loss and Take Profit of a Market Order ... limit ordres?

Hi I am wondering if sl and tp of market orders are limit or market orders? the same question please for limit orders. Regards

Simulating SL and TP indirectly

I like, to avoid brokers possible excessive slippage, make a routine that continuously check for my open positions and: 1. if profit of a position is above the wanted profit, close that position with minimal deviation. if the position is not successfully closed due to the deviation unachievable

CHART_PRICE_MIN giving sometimes zero

The following script works for Subwindow=0, not for Subwindow=1 (it will return both values as 0) void OnStart () { double priceMin= ChartGetDouble ( 0 , CHART_PRICE_MIN , 1 ); double priceMax= ChartGetDouble ( 0 , CHART_PRICE_MAX , 1 ); Print (" CHART_PRICE_MIN =",priceMin); Print ("

Asking for Zigzag indicators values return weird results

I am trying to use Zigzag indicator values in numerous applications, say for example support and resistance determination. This code, which I believe worked in the past for me, is showing now weird results: int n = 200 ; //how many candles to check back int Handle= iCustom (_Symbol,_Period

ChartTimePriceToXY giving same (wrong) results

I am trying to use an indicator only as dashboard to draw rectangles, labels, present information... As drawing objects is easier with X and Y coordinates, I will end up using OBJ_LABEL and OBJ_RECTANGLE_LABEL ... But the indicator subwindow is based (?) on datetime and prices. The necessary

Making an indicator see the higher timeframe

I am editing the MQL5 downloadable indicator " MACD.mq5 " to make it show the higher time frame MACD instead of the current one, but with no success. the main code I inserted is: input bool FractalTime = true ; // Fractal Application //... //... //--- Get the proper timeframe

Is history gets simulated during backtesting?

Hi, I like to know if functions like:HistorySelect(), and HistoryDealGetTicket() are being allowed during backtesting . In other words, does History cache gets filled with the simulated trades

Knowing the profit of the last closed position

With two trials to get the profit of the last closed position (Hedging account), I am not arriving anywhere. The first trial is personal, and it goes like this: //+------------------------------------------------------------------+ //| Ask: MQL4 emulation