View Single Post
  #2 (permalink)  
Old 01-25-2006, 01:34 AM
mbkennel mbkennel is offline
Junior Member
 
Join Date: Sep 2005
Posts: 5
mbkennel is on a distinguished road
What you need to do is to have a "static" variable which is something like

"bool ITradedOnThisBar;"

Which is cleared to 'false' every time you have a new bar, and set
to "true" whenever each new trade is signaled.

You check for a new bar by saving the Bar time, e.g. Time[0];
into a variable (check for the right data type) also static or
declared globally.

Then when you enter start(), which happens on each new tick,
you then check the present Time[0] and compare---if unequal
there is a new bar. You can set a boolean variable for that too.


I
Reply With Quote