Creating a TickCounter using MqlTick and CopyTicks [suggestions plz] - page 3

 
thien_v:

I think you have to delete the info in the array everytime a new tick is created(freememory), when you are using copyticks they only copy the number that you have put into the array at time 0. Newest tick will not be created...

 Example;

 MqlTick ticks[];
 int copied=CopyTicks(NULL,ticks,COPY_TICKS_TRADE,0,10); // You will only get 10 lastest ticks at time 0. When time is 1, it will generate an amount of new tick. right? This function will  stand at same place. I think you have to refresh it, freememory and make a new copy then for every new tick. Then you can compare current tick.

 

MqlTick ticks[]; 

int copied=CopyTicks(NULL,ticks,COPY_TICKS_TRADE,0,10);

"Your function... make comparison with current tick";

ArrayFree(ticks);  // void  ArrayFree( void&  array[]      // array  ); 

  

 


 

 



 
thien_v:

 



You quoted your self and write inside the quote. It's totally unclear.
 

Hi, so what is your solution? Thanks in advance. :) 

 
thien_v:

Hi, so what is your solution? Thanks in advance. :) 

Don't quote yourself, edit your post.


Reason: