Obviously they do, but where is the data stored! I am importing quotes for another instrument - Si futures and I need to remove the zeros after the decimal point there, as they are not in Si.
Then let's start from the other side: how do you import?
Vitalie Postolache: This way the script can be "corrected" so that the final file contains quotes in the right format, but whether the terminal will display them without the fractional part, I'm not sure. Most likely, there will be zeros after importing into the terminal. Ask the author of the script.
That's what I'm saying, there are zeros! Otherwise, everything works. And these zeros bother me - astronomical numbers in points spoil the perception.
Vitalie Postolache: Then all that remains is to hide the chart prices and draw your own objects, but is it worth it? What do the zeros prevent from, the aesthetics are wrong?
Zeros prevent us from doing this because we have to reconfigure the EA globally in those places where points are used - it's a waste of time.
voidOnTick(void){ double LB=0, LS=0; int b=0,s=0; for(int i=0; i<OrdersTotal(); i++){ if(OrderSelect(i,SELECT_BY_POS,MODE_TRADES)){ if(OrderSymbol()==Symbol()){ int tip = OrderType();
if (tip==OP_BUY){ LB += OrderLots(); b++; } if (tip==OP_SELL){ LS += OrderLots(); s++;
}}}} Comment(b," Buy ",DoubleToStr(LB,2)," lot"," \n",s," Sell ",DoubleToStr(LS,2)," lot"); if (LS<LB){ if(OrderSend(Symbol(),OP_SELL,Lots,NormalizeDouble(Bid,Digits),100,0, stoploss, NULL,0,0,CLR_NONE)==-1) Print("Error ",GetLastError()," order opening
} if (LS>LB){ if(OrderSend(Symbol(),OP_BUY,Lots,NormalizeDouble(Ask,Digits),100,0, takeprofit, NULL,0,0,CLR_NONE)==-1) Print("Error ",GetLastError()," order opening "); }
It works on the principle of locking each open trade...I.e., a trade is opened and it immediately covers it with the opposite one and so on to infinity...
I have to do it this way! When a deal was opened (or I myself kinda opened it), and if it was successful, it was safely closed... And if it was not justified, then after nth number (which can be specified in settings) tick opened the lock and held this position... I mean, logic is clear? If not, I'll try to explain the point in more detail...
Please help good people.... I will be very grateful
Allow the use of cookies to log in to the MQL5.com website.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.
You are signed in. Two-factor authentication has been disabled. Set it up again and scan a new QR code, or continue with two-factor authentication disabled.
Obviously they do, but where is the data stored! I am importing quotes for another instrument - Si futures and I need to remove the zeros after the decimal point there, as they are not in Si.
Then let's start on the other side: how do you import?
Выгружаю при помощи скрипта https://www.mql5.com/ru/code/232?utm_campaign=MetaTrader+5+Terminal&utm_medium=special&utm_source=mt5terminal+codebase&utm_link=de35e1ae8016b5df5acf9cef409f1632&utm_codepage=1049&utm_gid=8881077233567656571&utm_uniq=FF3D0E2E-CB4A-T
Just rework the script a little bit
It is enough to rework the script a bit
Which direction to rework - there are no zeros in the unloading.
Or, are you suggesting the other way round to split the integers?
This way the script can be "corrected" so that the final file contains quotes in the right format, but whether the terminal will display them without the fractional part, I'm not sure. Most likely, there will be zeros after importing into the terminal. Ask the author of the script.
Which direction to rework - there are no zeros in the unloading.
Or, do you propose to split the integers the other way round?
Then all that remains is to hide the chart prices and draw your own objects, but is it worth it? What do the zeros prevent from, the aesthetics are wrong?
Zeros get in the way because you have to reconfigure the EA globally in places where points are used - it's a waste of time.
It's easier to switch to a five then :)
A little help for a newbie with the code: