I found what I was interested in here (I couldn't find anything like that in the help): http://zulman.googlecode.com/svn/trunk/MT5/Indicators/ColorCandles.mq5. Is it correct to combine in your indicator what I was asking about, or not really, but in this example it is practiced and works without problems.
Who said you can't do it that way? It is written in the help that you can copy to an indicator buffer. From another indicator.
Rosh: Who said you can't do that? It says in the help that you can copy to the indicator buffer. From another indicator.
It's that simple. I had started copying errors using the above mentioned construction and a suspicion arose right there: maybe it is prohibited? When I looked through the reference for clarification, I found out that it contains many examples of SetIndexBuffer+CopyBuffer+INDICATOR_DATA, but together with INDICATOR_CALCULATIONS I have not found any example and decided that this may be a nuance that should be studied more thoroughly. But it turned out to be simpler.
heh, did I ask you a question? try to copy the code and run it in the tester))) maybe my hands are wrong)) in fact, in theory, the line
would not affect operability of Expert Advisor.
MqlTradeRequest structure has more fields than you use, and therefore they contain rubbish. The point is that mrequest variable is local (it's in stack) and presence or absence of other local variables lying in the stack affect the content of uninitialized fields. In one case, you are "lucky" and there appear values suitable for OrderSend, while in another case, you are not.
sergeev: is that a compliment to MQL or don't you know about other platforms?
It's an open-ended question, I'm wondering if it's worth transferring the basis of my developments to a DLL, for a flexible transition. I'm not happy with the prospect of rewriting everything every time
I found what I was interested in here (I couldn't find anything like that in the help): http://zulman.googlecode.com/svn/trunk/MT5/Indicators/ColorCandles.mq5. Is it correct to combine in your indicator what I was asking about, or not really, but in this example it is practiced and works without problems.
Who said you can't do that? It says in the help that you can copy to the indicator buffer. From another indicator.
Folks, I can't figure out why there are deals in the first case and no deals in the second?
heh, did I ask you a question? try to copy the code and run it in the tester))) maybe my hands are wrong)) in fact, in theory, the line
would not affect operability of Expert Advisor.
heh, did I ask you a question? try to copy the code and run it in the tester))) maybe my hands are wrong)) in fact, in theory, the line
would not affect operability of Expert Advisor.
heh, did I ask you a question? try to copy the code and run it in the tester))) maybe my hands are wrong)) in fact, in theory, the line
would not affect operability of Expert Advisor.
The point is that mrequest variable is local (it's in stack) and presence or absence of other local
variables lying in the stack affect the content of uninitialized fields.
In one case, you are "lucky" and there appear values suitable for OrderSend, while in another case, you are not.
Use ZeroMemory to zero the structure completely.
If you look at platforms in general, is DLL importing a what? An exception available in MQL or the norm?
If you look at platforms in general, DLL imports are what? An exception available in MQL or the norm?
is that a compliment to MQL or don't you know about other platforms?
I'm wondering if I should move the basis of my work to the DLL, for a flexible transition.