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
Can you please tell me why the alert is giving out Orders_Total=1, when in fact there is one position and one order, i.e. in theory it should give out 2, not 1
Try running the cycle backwards, from the end.
Try running the cycle backwards, from the end.
Didn't work ;(
Ah, you only have a position check:
That's where only positions are counted.Ah, you only have a position check:
That's where only positions count.The reference says that:
Either the date (year, month, date) or the time (hours, minutes, seconds) or all together can be omitted. The range of values is from 1 January 1970 to 31 December 3000.
Examples:
D'2004.01.01 00:00' // New Year
D'1980.07.19 12:30:27'
D'19.07.1980 12:30:27'
D'19.07.1980 12' //new year d'1980.07.19 12:00:00'
D'01.01.2004' //equivalent D'01.01.2004 00:00:00'
D'12:30:27' //equivalent to D'[compile date] 12:30:27'
D' '//equivalent to D'[compile date] 00:00:00''
Or am I misunderstanding this?
It didn't help ;(
Why are you adding flies and cutlets and then determining how many cutlets there are?
Orders count separately, positions separately. PositionGetSymbol() returns only the presence of a position by symbol, and does not say anything about orders. Since there is only one position, it gives out 1. And you're still lucky, since the loop parameter goes beyond the acceptable values (PositionsTotal), you can get anything you like.
P.S. You've already replied, I'm late.
I could not find any internal function or property to give the selectable property to graphical object (by default the object is drawn programmatically without selecting it with mouse), I found it only in the included graphics library. Obviously, the question is: is it possible to give a graphical object such a property normally, without additional libraries and other wizardry?
ObjectSetInteger
with prop_id=OBJPROP_SELECTABLE
ObjectSetInteger
with prop_id=OBJPROP_SELECTABLE
InOnCalculate I can easily use array elements like high by index. Is it also possible to access the index elements of this array in ExtFunc? When calling my function, should I pass the array-argument by reference, via pointer or something else? So far I've managed to minimize the error messages to: "'high' - parameter conversion is not allowed" and "'high' - constant variable cannot be passed as reference" regarding the same line of my function call with the array argument from OnCalculate. Is it hopeless or is there a solution?
So far in OnCalculate I have resorted to copying high to another array:
and then using CopyOfHigh in ExtFunc instead of using high-array directly.