[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 329

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
Look in the list of objects, maybe they are there, but with a crooked price, and, or time
I checked. No, they're not. I have tried everything.
Checked no. I've tried everything.
So you have one name for all objects, so you create the same object all the time.
So you have one name for all objects, so you create the same object all the time.
I added +Time[i] to the name
If you run from an init, the indicator will not find its window. This may be the reason. in any case, print out what ObjectCreate() returns to you and what goes into your function.
Can you please tell me what code is needed to make a long close at the maximum of the current EMA?
Doesn't anyone know how to write it?
Suppose, in the if statement, we specify to open a position at the minimum of the MA and to close it at the maximum.
But a stop is triggered and then the program starts to frantically open and
immediately close the long position, since daily bar conditions are fulfilled and vice versa.
HOW TO BYPASS THIS SITUATION, I.E. TO SPECIFY THAT THE LEVEL OF CLOSING THE LONG IS THE CURRENT MAXIMUM OF THE YEMA.
I have been working on this question for two days, but I have practically no experience in MQL .
I wrote a question herehttps://www.mql5.com/ru/forum/142582/page326#790513 .
If you don't look into my functions please advise how to implement so that an order is sent when a level of some indicator, e.g. rsi, is touched.
I.e. there is a level, for example, 50. The Expert Advisor should send a buy order when the price has touched this level. And only at this level. If the indicator value is higher, we will not buy. As I have implemented this task, you can see by following the link above. I would like to ask you to correct it. For some reason, some orders do not open where they should.
I wrote a question herehttps://www.mql5.com/ru/forum/142582/page326#790513 .
If you don't look into my functions please advise how to implement so that an order is sent when a level of some indicator, e.g. rsi, is touched.
I.e. there is a level, for example, 50. The Expert Advisor should send a buy order when the price has touched this level. And only at this level. If the indicator value is higher, we will not buy. As I have implemented this task, you can see by following the link above. I would like to ask you to correct it. For some reason, some of the orders do not open where they should.
1) You must understand exactly what "touched" means.
2) Remember that you can know the position of the indicator (as well as any line on the chart) you can know only at the open candle point, what happens inside the candle you can learn only when you go down in TF (to a smaller), and also only by time (opening price).
3) You can not identify the "touch" - you can only understand that at one point, one line was below the other, and the next one was higher (ie, crossing).
Once you realise this for yourself, everything will go right back to normal.