[ARCHIVE]Any rookie question, so as not to clutter up the forum. Professionals, don't pass it by. Can't go anywhere without you - 5. - page 142

You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
IMHO - better to search for your order and see if it is in the market or closed, and how it closed, at take, stop or manually. From here we will start dancing in different directions.
Then everything will be accurate. And global variables can be lost...
Global variables, as I heard, can be written to a file...
Global variables, from what I hear, can be written to a file...
You can also write to a file. You're the boss -))))
Need help from the pros!!! Already racked my brain with this code... There are 4 buffers 2 of them work correctly (Buffer &buffer2), but the other 2 don't. When a certain condition occurs buffer is filled, when this value up for one and down for the second, buffers are removed (zeroed), but the remaining 2 buffers are still hanging in the chart. Can you tell me how to fix it?
Try it like this:
I ran into this once a long time ago, but I've forgotten. There's a bit of an ambush there.https://www.mql5.com/ru/forum/101632 have a look.
Hello. In the settings of the Ilan1.6Dynamic Expert Advisor the tab where the lot volume is set is missing, how can I get it back?
Hello. In the settings of the Ilan1.6Dynamic Expert Advisor the tab where the lot volume is set is missing, how can I get it back?
Did you do something to the code? Or just like that, out of the blue?
Good evening everyone!
Please help me deal with trailing stop. If I have no trailing stop, my Expert Advisor works, sells and buys as I need it, but if I prescribe it, it just does not work! I have looked through all the books and the forum!
The problem: The EA does not work.
Some of the code only for buying:
int start()
{
int kolpos=0;
double MA=iMA(Symbol(),0,Period_MA,0,MODE_EMA,PRICE_CLOSE,0);
//----
for (int pos=0; pos<OrdersTotal(); pos++)
{
OrderSelect(pos,SELECT_BY_POS,MODE_TRADES);
if (OrderSymbol()==Symbol()&&OrderMagicNumber()==Magic)
kolpos++;
}
if (kolpos==0)
{
if (MA<Close[1]&&Open[1]<MA&Volume[0]>3)
OrderSend(Symbol(),OP_BUY,Lot,Ask,7,Ask-SL*Point,Ask+TP*Point,NULL,Magic,0,Green);
}
if (OrderType()==OP_BUY)
{
if (TS*Point+OrderOpenPrice() <Bid-MarketInfo(Symbol(),MODE_STOPLEVEL)*Point)
{
if (OrderModify(Magic,OrderOpenPrice(),SL*Point+TS*Point,OrderTakeProfit(),OrderExpiration(),Green)
return(0)
What to do? What is wrong here?
Try this:
I ran into this once a long time ago, but I've forgotten. There's a bit of an ambush there.https://www.mql5.com/ru/forum/101632 look it up.
It doesn't fit. You see, everything works, but it's the second buffers that don't reset along with the first, if necessary... that's the snag, visually everything works correctly, but the buffers remain on the chart and when you move the cursor over the graph, phantom values from the old objects that were in the second buffers appear in the data window
Let's say this picture here... graphically there is nothing anymore and the first buffer Dn is empty, but the value is not deleted from the second buffer
I'm starting to read about MQL4, so I don't know anything.
Can I write an EA that always works on the same timeframe? For example, if my EA only opens trades on H1 Moving Average, but you are on H4 timeframe. That is, it is not clear how to get information about bars from H1. I think I can calculate the H1 MA from the minute ones.
Maybe there is an example?