//+------------------------------------------------------------------+ //| comment.mq4 | //| Copyright 2017, MetaQuotes Software Corp. | //| https://www.mql5.com | //+------------------------------------------------------------------+ #property copyright "Copyright 2017, MetaQuotes Software Corp." #property link "https://www.mql5.com" #property version "1.00" #property strict #property indicator_chart_window #property indicator_buffers 2; double BufUP_Arrow[]; double BufDOWN_Arrow[]; //+------------------------------------------------------------------+ //| Custom indicator initialization function | //+------------------------------------------------------------------+ int OnInit() { SetIndexBuffer(0,BufUP_Arrow); SetIndexStyle(0,DRAW_ARROW,EMPTY,1,Blue); SetIndexArrow(0,233); SetIndexBuffer(1,BufDOWN_Arrow); SetIndexStyle(1,DRAW_ARROW,EMPTY,1,Blue); SetIndexArrow(1,234); return(INIT_SUCCEEDED); } int start() { int limit = Bars - IndicatorCounted(); for(int i=0; i Open[i]) { BufUP_Arrow[i] = Low[i]; } if(Close[i] < Open[i]) { BufDOWN_Arrow[i] = High[i]; } } return(0); }