assfianazhar: i dont know the right method that how should i write it, and what information i need to store.
- There are multiple depending on what you need. Circular queue would be one.
- There are no mind readers here and our crystal balls are cracked. Only you can know what you need.
William Roeder:
- There are multiple depending on what you need. Circular queue would be one.
- There are no mind readers here and our crystal balls are cracked. Only you can know what you need.
i am Sorry. and thankyou for replying in this thread.
What i am trying to ask is that how can i store the previous tick prices in an array.
I have done this so far, but this code is storing the same price in all indexes. how can i make it store each new value in 0 index and move previous value to the 1 or next index.
MqlTick TickData ; double tickarray[11]; static int cnt=10; double temp = TickData.ask; for (int i=10; i>1; i--) { if ( SymbolInfoTick(Symbol(),TickData)) { double temp = TickData.ask; Alert (temp); Sleep(500); }
assfianazhar: I have done this so far, but this code is storing the same price in all indexes. how can i make it store each new value in 0 index and move previous value to the 1 or next index.
- Of course, it does. Store one value and return until you get a new tick.
- Show your code that moves values higher and stores into [0].
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
hello everyone.
I am looking to save previous 10 prices changes in an array, and use these prices to see if the current price is above or lower then last price. I want to do this becuase i want to manage open orders.
I know i have to create an array. but i dont know the right method that how should i write it, and what information i need to store. if Anyone could help ?