hello all,
i dont understand how to plot arrows in terminal..I have seen many mq4 files for candle stick pattern recognition but could not understand
why the objectcreate and objectset are different commands in mql language...
objectcreate creates objects in memory only,then why they arre created if not plotted....i think objectcreate should be merged into objectset for making mql more easy to understand....
whats the purpose of index parameter in ObjectSet(
string name, int index, double value) command..??
The index parameter tells ObjectSet() what property of the object it is effecting/setting, for example: colour, line width, line style, font, price1, time1, etc.
but how to draw arrows on graph..cant understand clearly from documentation..
whats the purpose of price2 and time2 ??
A Trend Line has a start, Price1, Time1 and an end, Price2, Time2 . . . other objects like a Horizontal Line or an Arrow have 1 set of coordinates, Price1, Time1 if you look at the documentation it tells you this . . .
OBJ_ARROW "OBJ_ARROW 22 Arrows. Uses 1 coordinate."
A Trend Line has a start, Price1, Time1 and an end, Price2, Time2 . . . other objects like a Horizontal Line or an Arrow have 1 set of coordinates, Price1, Time1 if you look at the documentation it tells you this . . .
OBJ_ARROW "OBJ_ARROW 22 Arrows. Uses 1 coordinate."
int start() { int limit; int counted_bars=IndicatorCounted(); //---- check for possible errors if(counted_bars<0) return(-1); //---- the last counted bar will be recounted if(counted_bars>0) counted_bars--; limit=Bars-counted_bars; //---- main loop for(int i=0; i<limit; i++){ ObjectCreate("any",OBJ_ARROW,0,Time[0],High[0]); ObjectSet("any",OBJPROP_ARROWCODE,SYMBOL_ARROWDOWN); }
not working !!!!!!
want to draw arrows on each bar in daily frame...
not working !!!!!!
want to draw arrows on each bar in daily frame...
Off course that's not working :D
To draw several objects, you have to set different name for each object. Your code there show that you trying to draw several object but each one of them have the same name.
And also if you want to draw several objects on each bar, then why you set the same coordinate for each of the object ?
int start() { int limit; int counted_bars=IndicatorCounted(); //---- check for possible errors if(counted_bars<0) return(-1); //---- the last counted bar will be recounted if(counted_bars>0) counted_bars--; limit=Bars-counted_bars; //---- main loop string name = ""; for(int i=0; i<limit; i++) { name = "any "+ i; ObjectCreate(name,OBJ_ARROW,0,Time[i],High[i]); ObjectSet(name,OBJPROP_ARROWCODE,SYMBOL_ARROWDOWN); ObjectSet(name,OBJPROP_TIME1, Time[i]); ObjectSet(name,OBJPROP_PRICE1,High[i]); WindowRedraw(); } return (0); }
whats the use of WindowRedraw();??

- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
hello all,
i dont understand how to plot arrows in terminal..I have seen many mq4 files for candle stick pattern recognition but could not understand
why the objectcreate and objectset are different commands in mql language...
objectcreate creates objects in memory only,then why they arre created if not plotted....i think objectcreate should be merged into objectset for making mql more easy to understand....
whats the purpose of index parameter in ObjectSet( string name, int index, double value) command..??